commit c83526507ddf6cd8b395c03cafe011d92efdc1a4
Author: David Sorber <dsorber@prometheus.fios-router.home>
Date:   Tue Feb 21 17:56:03 2017 -0500

    WIP commit, stashing these debugging changes so I can go mobile.

diff --git a/software/photo_compress_archiver/PhotoCompressArchiver.cc b/software/photo_compress_archiver/PhotoCompressArchiver.cc
index 36af5ec..5722371 100644
--- a/software/photo_compress_archiver/PhotoCompressArchiver.cc
+++ b/software/photo_compress_archiver/PhotoCompressArchiver.cc
@@ -266,6 +266,17 @@ void PhotoCompressArchiver::fork_worker(
             ++sublist_idx;
         }
         
+#if 1
+        // DEBUGGING
+        uint32_t idx = 0;
+        for (auto outfile : output_filenames)
+        {
+            OUT(std::cout << "T[" << tid << "] output file: " << outfile 
+                          << "\ninput file:  " << exec_argv[idx++] << std::endl;)
+        }
+        continue;
+#endif 
+        
         // Add a nullptr to the end of the argv array as a terminator
         exec_argv.push_back(nullptr);
 
@@ -313,7 +324,7 @@ void PhotoCompressArchiver::fork_worker(
         int stat_rc = 0;
         struct stat statbuf;
         double complete_percent = 0.0;
-        while (output_idx < output_filenames.size())
+        while (output_idx < (output_filenames.size() - 1))
         {
             // Poll, waiting for output file X + 1 to exist
             bailout_ctr = 0;
diff --git a/software/photo_compress_archiver/packJPG/bitops.cpp b/software/photo_compress_archiver/packJPG/bitops.cpp
index d4fa8dd..fff0983 100644
--- a/software/photo_compress_archiver/packJPG/bitops.cpp
+++ b/software/photo_compress_archiver/packJPG/bitops.cpp
@@ -8,7 +8,7 @@ reading and writing of arrays
 #include <algorithm>
 #include <array>
 #include <cstdio>
-#include <stdlib.h>
+#include <cstdlib>
 #include <vector>
 
 #if defined(_WIN32) || defined(WIN32)
