-
Notifications
You must be signed in to change notification settings - Fork 14.9k
Closed
Labels
Description
See:
llvm-project/lldb/tools/debugserver/source/RNBRemote.cpp
Lines 43 to 45 in f15b60b
#include <compression.h> | |
How it should be:
llvm-project/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
Lines 49 to 51 in f15b60b
#if defined(HAVE_LIBCOMPRESSION) | |
#include <compression.h> | |
#endif |
This was detected while updating the nixpkgs
for llvm-10.
Similarly
llvm-project/lldb/tools/debugserver/source/RNBRemote.cpp
Lines 715 to 761 in f15b60b
case compression_types::zlib_deflate: | |
scratchbuf_size = compression_encode_scratch_buffer_size (COMPRESSION_ZLIB); | |
break; | |
case compression_types::lzma: | |
scratchbuf_size = compression_encode_scratch_buffer_size (COMPRESSION_LZMA); | |
break; | |
case compression_types::lzfse: | |
scratchbuf_size = compression_encode_scratch_buffer_size (COMPRESSION_LZFSE); | |
break; | |
default: | |
break; | |
} | |
if (scratchbuf_size > 0) { | |
g_libcompress_scratchbuf = (void*) malloc (scratchbuf_size); | |
g_libcompress_scratchbuf_type = compression_type; | |
} | |
} | |
if (compression_type == compression_types::lz4) { | |
compressed_size = compression_encode_buffer( | |
encoded_data.data(), encoded_data_buf_size, | |
(const uint8_t *)orig.c_str(), orig.size(), | |
g_libcompress_scratchbuf, | |
COMPRESSION_LZ4_RAW); | |
} | |
if (compression_type == compression_types::zlib_deflate) { | |
compressed_size = compression_encode_buffer( | |
encoded_data.data(), encoded_data_buf_size, | |
(const uint8_t *)orig.c_str(), orig.size(), | |
g_libcompress_scratchbuf, | |
COMPRESSION_ZLIB); | |
} | |
if (compression_type == compression_types::lzma) { | |
compressed_size = compression_encode_buffer( | |
encoded_data.data(), encoded_data_buf_size, | |
(const uint8_t *)orig.c_str(), orig.size(), | |
g_libcompress_scratchbuf, | |
COMPRESSION_LZMA); | |
} | |
if (compression_type == compression_types::lzfse) { | |
compressed_size = compression_encode_buffer( | |
encoded_data.data(), encoded_data_buf_size, | |
(const uint8_t *)orig.c_str(), orig.size(), | |
g_libcompress_scratchbuf, | |
COMPRESSION_LZFSE); | |
} | |
needs to be adapted.