Index: trunk/magic/remove/src/streaksio.c
===================================================================
--- trunk/magic/remove/src/streaksio.c	(revision 24853)
+++ trunk/magic/remove/src/streaksio.c	(revision 25082)
@@ -12,5 +12,5 @@
 // Assumptions about the file structure of non-raw files
 // The 'image' for each file (image, mask weight) is contained in the first
-// extension. 
+// extension.
 
 
@@ -625,5 +625,5 @@
         streaksExit("", PS_EXIT_DATA_ERROR);
     }
- 
+
     bool status;
     in->extname = psMetadataLookupStr(&status, in->header, "EXTNAME");
@@ -654,5 +654,4 @@
             streaksExit("", PS_EXIT_DATA_ERROR);
         }
-        psImage *image = (psImage *) (in->imagecube->data[0]);
     }
     setDataExtent(stage, in, (stage == IPP_STAGE_RAW) && !isMask);
@@ -925,6 +924,4 @@
 replicateOutputs(streakFiles *sfiles)
 {
-    bool status = false;
-
     if (!replicate(sfiles->outImage, sfiles->inImage)) {
         psError(PM_ERR_SYS, false, "failed to replicate outImage.");
@@ -973,5 +970,5 @@
 
         if (!nebSwap(server, in->name, out->name)) {
-            psError(PM_ERR_SYS, true, "failed to swap files for: %s.",
+            psError(PM_ERR_SYS, true, "failed to swap files for %s: %s.",
                 in->name, nebErr(server));
             return false;
@@ -1097,7 +1094,7 @@
 setMaskedToNAN(streakFiles *sfiles, psU32 maskMask, bool printCounts)
 {
-        int maskedPixels = 0;
-        int nandPixels = 0;
-        int nandWeights = 0;
+        long maskedPixels = 0;
+        long nandPixels = 0;
+        long nandWeights = 0;
 
         psImage *image = sfiles->outImage->image;
@@ -1120,5 +1117,5 @@
                 psU32 maskVal;
                 if (sfiles->stage == IPP_STAGE_RAW) {
-                    int xChip, yChip;
+                    unsigned int xChip, yChip;
                     cellToChipInt(&xChip, &yChip, sfiles->astrom, x, y);
                     maskVal = psImageGet(mask, xChip, yChip);
@@ -1144,5 +1141,5 @@
         if (printCounts) {
             psLogMsg(sfiles->program_name, PS_LOG_INFO, "time to NAN mask pixels: %f\n", psTimerClear("NAN_MASKED"));
-            int totalPixels = image->numRows * image->numCols;
+            long totalPixels = image->numRows * image->numCols;
             psLogMsg(sfiles->program_name, PS_LOG_INFO, "pixels:        %10ld\n", totalPixels);
             psLogMsg(sfiles->program_name, PS_LOG_INFO, "masked pixels: %10ld %4.2f%%\n", maskedPixels, 100. * maskedPixels / totalPixels);
