| OLD | NEW | 
|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be | 
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. | 
| 4 | 4 | 
| 5 #include "net/base/gzip_filter.h" | 5 #include "net/base/gzip_filter.h" | 
| 6 | 6 | 
| 7 #if defined(USE_SYSTEM_ZLIB) |  | 
| 8 #include <zlib.h> |  | 
| 9 #else |  | 
| 10 #include "third_party/zlib/zlib.h" |  | 
| 11 #endif |  | 
| 12 |  | 
| 13 #include "base/logging.h" | 7 #include "base/logging.h" | 
| 14 #include "net/base/gzip_header.h" | 8 #include "net/base/gzip_header.h" | 
|  | 9 #include "third_party/zlib/zlib.h" | 
| 15 | 10 | 
| 16 namespace net { | 11 namespace net { | 
| 17 | 12 | 
| 18 GZipFilter::GZipFilter() | 13 GZipFilter::GZipFilter() | 
| 19     : decoding_status_(DECODING_UNINITIALIZED), | 14     : decoding_status_(DECODING_UNINITIALIZED), | 
| 20       decoding_mode_(DECODE_MODE_UNKNOWN), | 15       decoding_mode_(DECODE_MODE_UNKNOWN), | 
| 21       gzip_header_status_(GZIP_CHECK_HEADER_IN_PROGRESS), | 16       gzip_header_status_(GZIP_CHECK_HEADER_IN_PROGRESS), | 
| 22       zlib_header_added_(false), | 17       zlib_header_added_(false), | 
| 23       gzip_footer_bytes_(0), | 18       gzip_footer_bytes_(0), | 
| 24       possible_sdch_pass_through_(false) { | 19       possible_sdch_pass_through_(false) { | 
| (...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 294     stream_data_len_ -= footer_byte_avail; | 289     stream_data_len_ -= footer_byte_avail; | 
| 295     next_stream_data_ += footer_byte_avail; | 290     next_stream_data_ += footer_byte_avail; | 
| 296     gzip_footer_bytes_ += footer_byte_avail; | 291     gzip_footer_bytes_ += footer_byte_avail; | 
| 297 | 292 | 
| 298     if (stream_data_len_ == 0) | 293     if (stream_data_len_ == 0) | 
| 299       next_stream_data_ = NULL; | 294       next_stream_data_ = NULL; | 
| 300   } | 295   } | 
| 301 } | 296 } | 
| 302 | 297 | 
| 303 }  // namespace net | 298 }  // namespace net | 
| OLD | NEW | 
|---|