From 56de283899bc91f7110aba58a3ca174c10852683 Mon Sep 17 00:00:00 2001 From: wolfbeast Date: Thu, 14 Nov 2019 09:07:29 +0100 Subject: Issue #1288 - Part 1a: Update brotli to 1.0.7 This also reorganizes the exports in the build system to use `brotli/` as include directory. --- modules/brotli/enc/encoder_dict.c | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 modules/brotli/enc/encoder_dict.c (limited to 'modules/brotli/enc/encoder_dict.c') diff --git a/modules/brotli/enc/encoder_dict.c b/modules/brotli/enc/encoder_dict.c new file mode 100644 index 000000000..8b2f6ad4a --- /dev/null +++ b/modules/brotli/enc/encoder_dict.c @@ -0,0 +1,32 @@ +/* Copyright 2017 Google Inc. All Rights Reserved. + + Distributed under MIT license. + See file LICENSE for detail or copy at https://opensource.org/licenses/MIT +*/ + +#include "./encoder_dict.h" + +#include "../common/dictionary.h" +#include "../common/transform.h" +#include "./dictionary_hash.h" +#include "./hash.h" + +#if defined(__cplusplus) || defined(c_plusplus) +extern "C" { +#endif + +void BrotliInitEncoderDictionary(BrotliEncoderDictionary* dict) { + dict->words = BrotliGetDictionary(); + + dict->hash_table = kStaticDictionaryHash; + dict->buckets = kStaticDictionaryBuckets; + dict->dict_words = kStaticDictionaryWords; + + dict->cutoffTransformsCount = kCutoffTransformsCount; + dict->cutoffTransforms = kCutoffTransforms; + +} + +#if defined(__cplusplus) || defined(c_plusplus) +} /* extern "C" */ +#endif -- cgit v1.2.3