Fix decompress PoolByteArray crash

This commit is contained in:
qarmin 2019-10-10 17:15:10 +02:00
parent 0148112730
commit 684156f711
1 changed files with 2 additions and 2 deletions

View File

@ -591,9 +591,9 @@ struct _VariantCall {
int buffer_size = (int)(*p_args[0]); int buffer_size = (int)(*p_args[0]);
if (buffer_size < 0) { if (buffer_size <= 0) {
r_ret = decompressed; 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); decompressed.resize(buffer_size);