- Fixed memory leak in ob_get_clean/ob_get_flush. (Christian)
- Fixed segfault on invalid session.save_path. (Hannes)
+- Fixed bug #47903 ("@" operator does not work with string offsets). (Felipe)
- Fixed bug #47845 (PDO_Firebird omits first row from query). (Lars W)
- Fixed bug #47831 (Compile warning for strnlen() in main/spprintf.c).
(Ilia, rainer dot jung at kippdata dot de)
list($a, $b) = $s[0];
?>
--EXPECTF--
-Fatal error: Cannot use string offset as an array in %sbug39304.php on line 3
+Notice: Uninitialized string offset: 0 in %s on line %d
+
+Fatal error: Cannot use string offset as an array in %sbug39304.php on line %d
echo "ok\n";
?>
--EXPECTF--
+Notice: Uninitialized string offset: 3 in %s on line %d
+
Fatal error: Cannot use string offset as an object in %sbug41919.php on line %d
if (T->str_offset.str->type != IS_STRING
|| ((int)T->str_offset.offset < 0)
|| (T->str_offset.str->value.str.len <= (int)T->str_offset.offset)) {
- zend_error(E_NOTICE, "Uninitialized string offset: %d", T->str_offset.offset);
ptr->value.str.val = STR_EMPTY_ALLOC();
ptr->value.str.len = 0;
} else {
break;
}
if (result) {
+ if (Z_LVAL_P(dim) < 0 || Z_STRLEN_P(container) <= Z_LVAL_P(dim)) {
+ zend_error(E_NOTICE, "Uninitialized string offset: %ld", Z_LVAL_P(dim));
+ }
container = *container_ptr;
result->str_offset.str = container;
PZVAL_LOCK(container);