# HG changeset patch # User Carl Byington # Date 1302975092 25200 # Node ID 78e95fab9a8bca457fa03080cab806519f37daf5 # Parent 8ad8fd1c5451fc75c816ca1db93b26351dbe9322 add some debug checking for process exit status diff -r 8ad8fd1c5451 -r 78e95fab9a8b regression/regression-tests.bash --- a/regression/regression-tests.bash Sat Apr 16 10:09:28 2011 -0700 +++ b/regression/regression-tests.bash Sat Apr 16 10:31:32 2011 -0700 @@ -65,7 +65,8 @@ #$val ../src/readpst $jobs -te -r -D -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 ## normal recursive dump - $val ../src/readpst $jobs -r -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 + $val ../src/readpst -j 10 -Sb -o output$n $fn >$ba.err 2>&1 + #$val ../src/readpst $jobs -r -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 ## separate mode with filename extensions #$val ../src/readpst $jobs -r -e -D -cv -o output$n -d $ba.log $fn >$ba.err 2>&1 diff -r 8ad8fd1c5451 -r 78e95fab9a8b src/readpst.c --- a/src/readpst.c Sat Apr 16 10:09:28 2011 -0700 +++ b/src/readpst.c Sat Apr 16 10:31:32 2011 -0700 @@ -161,9 +161,16 @@ pid_t ch = waitpid(child, &status, ((waitall) ? 0 : WNOHANG)); if (ch == child) { // check termination status + //if (WIFEXITED(status)) { + // int ext = WEXITSTATUS(status); + // printf("Process %d exited with status %d\n", child, ext); + // fflush(stdout); + //} if (WIFSIGNALED(status)) { int sig = WTERMSIG(status); DEBUG_INFO(("Process %d terminated with signal %d\n", child, sig)); + //printf("Process %d terminated with signal %d\n", child, sig); + //fflush(stdout); } // this has terminated, remove it from the list for (j=i; j