DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=22259>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=22259 deflate generates error when called with no data Summary: deflate generates error when called with no data Product: Apache httpd-2.0 Version: 2.0.47 Platform: PC OS/Version: Linux Status: NEW Severity: Normal Priority: Other Component: mod_deflate AssignedTo: [email protected] ReportedBy: [EMAIL PROTECTED] CC: [EMAIL PROTECTED] This bug was orignally reported against mod_perl, but was traced down to a problem in mod_deflate. If a print "" is done from a mod_perl script which mod_deflate active, the page output terminates and and error like this produced: [error] 673: ModPerl::RegistryBB: 20014:Error string not specified yet at /var/www/perl/test.pl line 6. Here is a patch (coded by Stas Bekman [EMAIL PROTECTED]) Index: modules/filters/mod_deflate.c =================================================================== RCS file: /home/cvs/httpd-2.0/modules/filters/mod_deflate.c,v retrieving revision 1.26.2.5 diff -u -r1.26.2.5 mod_deflate.c --- modules/filters/mod_deflate.c 17 May 2003 18:27:43 -0000 1.26.2.5 +++ modules/filters/mod_deflate.c 5 Aug 2003 06:37:59 -0000 @@ -529,9 +529,11 @@ if (APR_BUCKET_IS_FLUSH(e)) { apr_bucket *bkt; - zRC = deflate(&(ctx->stream), Z_SYNC_FLUSH); - if (zRC != Z_OK) { - return APR_EGENERAL; + if (ctx->stream.avail_in > 0) { + zRC = deflate(&(ctx->stream), Z_SYNC_FLUSH); + if (zRC != Z_OK) { + return APR_EGENERAL; + } } ctx->stream.next_out = ctx->buffer --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
