From 684156f7114bcc2d1d95f77c50add11a1eb7b2ce Mon Sep 17 00:00:00 2001 From: qarmin Date: Thu, 10 Oct 2019 17:15:10 +0200 Subject: [PATCH] Fix decompress PoolByteArray crash --- core/variant_call.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/variant_call.cpp b/core/variant_call.cpp index 1b5ca9d3e5d..8a64ee4e2f1 100644 --- a/core/variant_call.cpp +++ b/core/variant_call.cpp @@ -591,9 +591,9 @@ struct _VariantCall { int buffer_size = (int)(*p_args[0]); - if (buffer_size < 0) { + if (buffer_size <= 0) { r_ret = decompressed; - ERR_FAIL_MSG("Decompression buffer size is less than zero."); + ERR_FAIL_MSG("Decompression buffer size must be greater than zero."); } decompressed.resize(buffer_size);