Skip to content

Commit 08d2e51

Browse files
committed
Merge branch 'PHP-7.4' into master
* PHP-7.4: Fix #80002: calc free space for new interned string is wrong
2 parents 9395e01 + 10df94d commit 08d2e51

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/opcache/ZendAccelerator.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -493,7 +493,7 @@ zend_string* ZEND_FASTCALL accel_new_interned_string(zend_string *str)
493493
} while (pos != STRTAB_INVALID_POS);
494494
}
495495

496-
if (UNEXPECTED(ZCSG(interned_strings).end - ZCSG(interned_strings).top < STRTAB_STR_SIZE(str))) {
496+
if (UNEXPECTED((char*)ZCSG(interned_strings).end - (char*)ZCSG(interned_strings).top < STRTAB_STR_SIZE(str))) {
497497
/* no memory, return the same non-interned string */
498498
zend_accel_error(ACCEL_LOG_WARNING, "Interned string buffer overflow");
499499
return str;

0 commit comments

Comments
 (0)