Please do not reply directly to this email. All additional comments should be made in the comments box of this bug report.
Summary: Review Request: perl-CGI-SpeedyCGI - Speed up perl scripts by running them persistently
https://bugzilla.redhat.com/show_bug.cgi?id=429609
------- Additional Comments From jorton@redhat.com 2008-01-25 10:40 EST ------- The patch will compile and work. mod_speedycgi2.c is a rather stale fork of upstream mod_cgi.c and lacks the improvements and bug fixes from over a couple of years.
w.r.t to code changed in the patch itself, the second loop is OK, but the discard_script_output loop is sub-optimal, it should look something like this: (untested)
while ((e = APR_BRIGADE_FIRST(bb)) != APR_BRIGADE_SENTINEL(bb)) { if (APR_BUCKET_IS_EOS(e)) { break; }
rv = apr_bucket_read(e, &buf, &len, APR_BLOCK_READ); if (rv != APR_SUCCESS) { break; }
apr_bucket_delete(e); }