mirror of
https://github.com/BeamMP/BeamMP-Launcher.git
synced 2025-07-01 15:36:10 +00:00
reduce compression to 3 instead of 6
This commit is contained in:
parent
7c24020124
commit
3ca6e7fd3d
@ -19,11 +19,12 @@ std::vector<char> Comp(std::span<const char> input) {
|
||||
auto max_size = compressBound(input.size());
|
||||
std::vector<char> output(max_size);
|
||||
uLongf output_size = output.size();
|
||||
int res = compress(
|
||||
int res = compress2(
|
||||
reinterpret_cast<Bytef*>(output.data()),
|
||||
&output_size,
|
||||
reinterpret_cast<const Bytef*>(input.data()),
|
||||
static_cast<uLongf>(input.size()));
|
||||
static_cast<uLongf>(input.size()),
|
||||
3);
|
||||
if (res != Z_OK) {
|
||||
error("zlib compress() failed: " + std::to_string(res));
|
||||
throw std::runtime_error("zlib compress() failed");
|
||||
|
Loading…
x
Reference in New Issue
Block a user