Line count should be inside the loop. As it is now, it will always be 1 if there are no stderr lines. This code is also incorrect in 5.0.28 Line count algorithm is incorrect private void sendToLog(BufferedReader rdr) { String line = null; int lineCount = 0 ; try { while ((line = rdr.readLine()) != null) { log("runCGI (stderr):" + line) ; } ---> lineCount++ ; } catch (IOException e) { log("sendToLog error", e) ; } finally { try { rdr.close() ; } catch (IOException ce) { log("sendToLog error", ce) ; } ; } ; if ( lineCount > 0 && debug > 2) { log("runCGI: " + lineCount + " lines received on stderr") ; } ; }
Fix in CVS for 4.1.x and 5.5.x Thanks for the patch.
This is not a big deal, but can it be still fixed in 5.0.30?