From 008d23bb5c43e42369dc63470a19837f8f9a84ec Mon Sep 17 00:00:00 2001 From: Sascha Schumann Date: Tue, 14 Nov 2000 20:34:14 +0000 Subject: [PATCH] Fix allocation --- ext/standard/php_smart_str.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/standard/php_smart_str.h b/ext/standard/php_smart_str.h index 9626abd982..fce92af818 100644 --- a/ext/standard/php_smart_str.h +++ b/ext/standard/php_smart_str.h @@ -27,8 +27,8 @@ if (!d->c) d->len = d->a = 0; \ newlen = d->len + n; \ if (newlen >= d->a) {\ - d->c = perealloc(d->c, n + 129, what); \ - d->a = n + 128; \ + d->c = perealloc(d->c, newlen + 129, what); \ + d->a = newlen + 128; \ }\ } -- 2.50.1