diff options
author | Anna Henningsen <anna@addaleax.net> | 2018-11-27 10:16:34 +0900 |
---|---|---|
committer | Anna Henningsen <anna@addaleax.net> | 2019-01-05 21:36:46 +0100 |
commit | 73753d48639200f79957b822599e9848b0ac942f (patch) | |
tree | 5a5835afd3cf744d6ef86112524ee7bfe150df5c /src/node_metadata.cc | |
parent | b857d713f556dd06ee9a3696a7d6195b86a7ebdc (diff) | |
download | android-node-v8-73753d48639200f79957b822599e9848b0ac942f.tar.gz android-node-v8-73753d48639200f79957b822599e9848b0ac942f.tar.bz2 android-node-v8-73753d48639200f79957b822599e9848b0ac942f.zip |
zlib: add brotli support
Refs: https://github.com/nodejs/node/pull/20458
Co-authored-by: Hackzzila <admin@hackzzila.com>
PR-URL: https://github.com/nodejs/node/pull/24938
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Jan Krems <jan.krems@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Diffstat (limited to 'src/node_metadata.cc')
-rw-r--r-- | src/node_metadata.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/node_metadata.cc b/src/node_metadata.cc index ff8d408f5b..3bfed6d4b5 100644 --- a/src/node_metadata.cc +++ b/src/node_metadata.cc @@ -1,5 +1,6 @@ #include "node_metadata.h" #include "ares.h" +#include "brotli/encode.h" #include "nghttp2/nghttp2ver.h" #include "node.h" #include "util.h" @@ -72,6 +73,13 @@ Metadata::Versions::Versions() { llhttp = per_process::llhttp_version; http_parser = per_process::http_parser_version; + brotli = + std::to_string(BrotliEncoderVersion() >> 24) + + "." + + std::to_string((BrotliEncoderVersion() & 0xFFF000) >> 12) + + "." + + std::to_string(BrotliEncoderVersion() & 0xFFF); + #if HAVE_OPENSSL openssl = GetOpenSSLVersion(); #endif |