Merge branch 'PHP-7.1'

This commit is contained in:
Nikita Popov 2017-01-08 13:48:54 +01:00
commit f25f469088

View file

@ -1171,8 +1171,7 @@ PHP_FUNCTION(deflate_add)
if (ctx->avail_out == 0) {
/* more output buffer space needed; realloc and try again */
/* adding 64 more bytes solved every issue I have seen */
/* the + 1 is for the string terminator added below */
out = zend_string_realloc(out, ZSTR_LEN(out) + 64 + 1, 0);
out = zend_string_realloc(out, ZSTR_LEN(out) + 64, 0);
ctx->avail_out = 64;
ctx->next_out = (Bytef *) ZSTR_VAL(out) + buffer_used;
}