Index: /branches/eam_branches/ipp-20150625/Ohana/src/uniphot/src/update_dvo_setphot.c
===================================================================
--- /branches/eam_branches/ipp-20150625/Ohana/src/uniphot/src/update_dvo_setphot.c	(revision 38633)
+++ /branches/eam_branches/ipp-20150625/Ohana/src/uniphot/src/update_dvo_setphot.c	(revision 38634)
@@ -83,4 +83,18 @@
     if (VERBOSE) fprintf (stderr, "saving catalog %s\n", catalog.filename);
     
+    struct timeval now;
+    gettimeofday (&now, (void *) NULL);
+    char *moddate = ohana_sec_to_date (now.tv_sec);
+    gfits_modify (&catalog.header, "SETPHOT", "%s", 1, moddate); // replaces the single entry
+
+    char history[128];
+    snprintf (history, 128, "setphot applied: %s", moddate);
+    gfits_modify_alt (&catalog.header, "HISTORY", "%S", 0, history); // adds a new entry
+
+    snprintf (history, 128, "setphot options: reset: %1d, ubercal: %1d", RESET, UBERCAL);
+    gfits_modify_alt (&catalog.header, "HISTORY", "%S", 0, history); // adds a new entry
+
+    free (moddate);
+
     SetProtect (TRUE);
     if (!dvo_catalog_save (&catalog, VERBOSE)) { fprintf (stderr, "ERROR: failed to save %s\n", catalog.filename); exit (1); }
