Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(578)

Unified Diff: runtime/bin/filter.h

Issue 185773004: Use actual length of dictionary, and not size of a pointer, in zlib. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/bin/filter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/filter.h
diff --git a/runtime/bin/filter.h b/runtime/bin/filter.h
index 424fb3625a81ceec941582ed51e50fabe2ebaec6..c104c88fc4c3bbf0bead9daae3f4d8792187ed61 100644
--- a/runtime/bin/filter.h
+++ b/runtime/bin/filter.h
@@ -54,10 +54,10 @@ class ZLibDeflateFilter : public Filter {
public:
ZLibDeflateFilter(bool gzip, int32_t level, int32_t window_bits,
int32_t mem_level, int32_t strategy,
- uint8_t* dictionary, bool raw)
+ uint8_t* dictionary, intptr_t dictionary_length, bool raw)
: gzip_(gzip), level_(level), window_bits_(window_bits),
mem_level_(mem_level), strategy_(strategy), dictionary_(dictionary),
- raw_(raw), current_buffer_(NULL)
+ dictionary_length_(dictionary_length), raw_(raw), current_buffer_(NULL)
{}
virtual ~ZLibDeflateFilter();
@@ -73,6 +73,7 @@ class ZLibDeflateFilter : public Filter {
const int32_t mem_level_;
const int32_t strategy_;
uint8_t* dictionary_;
+ const intptr_t dictionary_length_;
const bool raw_;
uint8_t* current_buffer_;
z_stream stream_;
@@ -82,9 +83,10 @@ class ZLibDeflateFilter : public Filter {
class ZLibInflateFilter : public Filter {
public:
- ZLibInflateFilter(int32_t window_bits, uint8_t* dictionary, bool raw)
- : window_bits_(window_bits), dictionary_(dictionary), raw_(raw),
- current_buffer_(NULL)
+ ZLibInflateFilter(int32_t window_bits, uint8_t* dictionary,
+ intptr_t dictionary_length, bool raw)
+ : window_bits_(window_bits), dictionary_(dictionary),
+ dictionary_length_(dictionary_length), raw_(raw), current_buffer_(NULL)
{}
virtual ~ZLibInflateFilter();
@@ -96,6 +98,7 @@ class ZLibInflateFilter : public Filter {
private:
const int32_t window_bits_;
uint8_t* dictionary_;
+ const intptr_t dictionary_length_;
const bool raw_;
uint8_t* current_buffer_;
z_stream stream_;
« no previous file with comments | « no previous file | runtime/bin/filter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698