Patch wrong-array-access.diff for Scripting Engine problem Bug #54556
Patch version 2011-09-14 13:51 UTC
Return to Bug #54556 |
Download this patch
Patch Revisions:
Developer: dmitry@php.net
Index: Zend/zend_execute.c
===================================================================
--- Zend/zend_execute.c (revision 316741)
+++ Zend/zend_execute.c (working copy)
@@ -1249,11 +1249,6 @@
PZVAL_LOCK(*retval);
return;
- case IS_NULL:
- AI_SET_PTR(result, &EG(uninitialized_zval));
- PZVAL_LOCK(&EG(uninitialized_zval));
- return;
-
case IS_STRING: {
zval tmp;
zval *ptr;
@@ -1326,6 +1321,7 @@
return;
default:
+ zend_error(E_WARNING, "Cannot get offset of a non-array variable");
AI_SET_PTR(result, &EG(uninitialized_zval));
PZVAL_LOCK(&EG(uninitialized_zval));
return;
|