Index: branches/eam_branches/ohana.20170822/src/addstar/src/mkcmf.c
===================================================================
--- branches/eam_branches/ohana.20170822/src/addstar/src/mkcmf.c	(revision 40223)
+++ branches/eam_branches/ohana.20170822/src/addstar/src/mkcmf.c	(revision 40228)
@@ -254,5 +254,6 @@
     struct timeval now;
     gettimeofday (&now, NULL);
-    long A = now.tv_sec + now.tv_usec * 1000000;
+    int  B = getpid();
+    long A = now.tv_sec - now.tv_usec * 1000000 + B*100000;
     srand48(A);
   }
@@ -412,9 +413,12 @@
     gfits_modify (&header, "NINPUTS",         "%d", 1, 5);
 
+    // if we have multiple stacks using the same input image IDs, we run into trouble
+    int nFrame = 800 * drand48();
+
     int i;
     for (i = 0; i < 5; i++) {
       char field[64], expname[64];
       sprintf (field, "INP_%04d", i);
-      sprintf (expname, "o5745g01%02do.356%03d.wrp.1199763.skycell.1315.090.fits", i, i);
+      sprintf (expname, "o5745g01%02do.%03d%03d.wrp.1199763.skycell.1315.090.fits", i, nFrame, i);
       gfits_modify (&header, field, "%s", 1, expname);
 
