| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/filter/brotli_filter.h" | 5 #include "net/filter/brotli_filter.h" |
| 6 | 6 |
| 7 #include "base/bit_cast.h" |
| 7 #include "base/macros.h" | 8 #include "base/macros.h" |
| 8 #include "base/numerics/safe_conversions.h" | 9 #include "base/numerics/safe_conversions.h" |
| 9 #include "base/numerics/safe_math.h" | 10 #include "base/numerics/safe_math.h" |
| 10 #include "third_party/brotli/dec/decode.h" | 11 #include "third_party/brotli/dec/decode.h" |
| 11 | 12 |
| 12 namespace net { | 13 namespace net { |
| 13 | 14 |
| 14 // BrotliFilter applies Brotli content decoding to a data stream. | 15 // BrotliFilter applies Brotli content decoding to a data stream. |
| 15 // Brotli format specification: http://www.ietf.org/id/draft-alakuijala-brotli | 16 // Brotli format specification: http://www.ietf.org/id/draft-alakuijala-brotli |
| 16 // | 17 // |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 104 BrotliState brotli_state_; | 105 BrotliState brotli_state_; |
| 105 | 106 |
| 106 DISALLOW_COPY_AND_ASSIGN(BrotliFilter); | 107 DISALLOW_COPY_AND_ASSIGN(BrotliFilter); |
| 107 }; | 108 }; |
| 108 | 109 |
| 109 Filter* CreateBrotliFilter(Filter::FilterType type_id) { | 110 Filter* CreateBrotliFilter(Filter::FilterType type_id) { |
| 110 return new BrotliFilter(type_id); | 111 return new BrotliFilter(type_id); |
| 111 } | 112 } |
| 112 | 113 |
| 113 } // namespace net | 114 } // namespace net |
| OLD | NEW |