/[Apache-SVN]/httpd/httpd/trunk/modules/filters/mod_deflate.c
ViewVC logotype

Diff of /httpd/httpd/trunk/modules/filters/mod_deflate.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 563803, Wed Aug 8 10:39:23 2007 UTC revision 580598, Sat Sep 29 15:43:08 2007 UTC
# Line 293  typedef struct deflate_ctx_t Line 293  typedef struct deflate_ctx_t
293      int (*libz_end_func)(z_streamp);      int (*libz_end_func)(z_streamp);
294      unsigned char *validation_buffer;      unsigned char *validation_buffer;
295      apr_size_t validation_buffer_length;      apr_size_t validation_buffer_length;
296        int inflate_init;
297  } deflate_ctx;  } deflate_ctx;
298    
299  /* Number of validation bytes (CRC and length) after the compressed data */  /* Number of validation bytes (CRC and length) after the compressed data */
# Line 983  static apr_status_t inflate_out_filter(a Line 984  static apr_status_t inflate_out_filter(a
984  {  {
985      int zlib_method;      int zlib_method;
986      int zlib_flags;      int zlib_flags;
     int inflate_init = 1;  
987      apr_bucket *e;      apr_bucket *e;
988      request_rec *r = f->r;      request_rec *r = f->r;
989      deflate_ctx *ctx = f->ctx;      deflate_ctx *ctx = f->ctx;
# Line 1067  static apr_status_t inflate_out_filter(a Line 1067  static apr_status_t inflate_out_filter(a
1067          ctx->stream.next_out = ctx->buffer;          ctx->stream.next_out = ctx->buffer;
1068          ctx->stream.avail_out = c->bufferSize;          ctx->stream.avail_out = c->bufferSize;
1069    
1070          inflate_init = 0;          ctx->inflate_init = 0;
1071      }      }
1072    
1073      while (!APR_BRIGADE_EMPTY(bb))      while (!APR_BRIGADE_EMPTY(bb))
# Line 1172  static apr_status_t inflate_out_filter(a Line 1172  static apr_status_t inflate_out_filter(a
1172          apr_bucket_read(e, &data, &len, APR_BLOCK_READ);          apr_bucket_read(e, &data, &len, APR_BLOCK_READ);
1173    
1174          /* first bucket contains zlib header */          /* first bucket contains zlib header */
1175          if (!inflate_init++) {          if (!ctx->inflate_init++) {
1176              if (len < 10) {              if (len < 10) {
1177                  ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,                  ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
1178                                "Insufficient data for inflate");                                "Insufficient data for inflate");

Legend:
Removed from v.563803  
changed lines
  Added in v.580598

apache@apache.org
ViewVC Help
Powered by ViewVC 1.1.2