From 536e04ff8c9452ac799c7c53c0414bd3b75f3b56 Mon Sep 17 00:00:00 2001 From: John Denker Date: Sun, 15 Jul 2012 04:17:53 -0700 Subject: fancier log/progress message --- tools/hi-q.c | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) (limited to 'tools') diff --git a/tools/hi-q.c b/tools/hi-q.c index 0dc66d7..40d7100 100644 --- a/tools/hi-q.c +++ b/tools/hi-q.c @@ -203,7 +203,7 @@ int main(int argc, char** argv, char const * const * env) { if (job.size()) filter.push_back(job); } unsigned int nkids = filter.size(); - if (verbose) for (unsigned int ii = 0; ii < nkids; ii++) { + if (0 && verbose) for (unsigned int ii = 0; ii < nkids; ii++) { cerr << "hi-q filter[" << ii << "] :; "; for (VS::const_iterator token = filter[ii].begin(); token != filter[ii].end(); token++){ @@ -380,11 +380,23 @@ int main(int argc, char** argv, char const * const * env) { close(sync[wEnd]); // more housecleaning close(sync[rEnd]); - close(0); // the reading end of stdin was - // delegated to the first child + close(0); // Housecleaning: the reading end of stdin was + // delegated to the first child, + // so we don't need it. + + if (verbose) for (unsigned int ii = 0; ii < nkids; ii++) { + cerr << "hi-q filter[" << ii << "] " + << kidpid[ii] + << " :; "; + for (VS::const_iterator token = filter[ii].begin(); + token != filter[ii].end(); token++){ + cerr << *token << " "; + } + cerr << endl; + } for (unsigned int ii=0; ii