Index: zend_execute.c =================================================================== RCS file: /repository/ZendEngine2/zend_execute.c,v retrieving revision 1.792 diff -u -r1.792 zend_execute.c --- zend_execute.c 8 Mar 2008 11:49:24 -0000 1.792 +++ zend_execute.c 13 Apr 2008 10:05:09 -0000 @@ -932,13 +932,13 @@ efree(offset_key.v); } break; - case IS_RESOURCE: - zend_error(E_STRICT, "Resource ID#%ld used as offset, casting to integer (%ld)", Z_LVAL_P(dim), Z_LVAL_P(dim)); - /* Fall Through */ case IS_DOUBLE: index = (long)Z_DVAL_P(dim); goto num_index; + case IS_RESOURCE: + zend_error(E_STRICT, "Resource ID#%ld used as offset, casting to integer (%ld)", Z_LVAL_P(dim), Z_LVAL_P(dim)); + /* Fall Through */ case IS_BOOL: case IS_LONG: index = Z_LVAL_P(dim); Index: zend_vm_def.h =================================================================== RCS file: /repository/ZendEngine2/zend_vm_def.h,v retrieving revision 1.223 diff -u -r1.223 zend_vm_def.h --- zend_vm_def.h 11 Apr 2008 09:43:49 -0000 1.223 +++ zend_vm_def.h 13 Apr 2008 10:05:10 -0000 @@ -3001,6 +3001,9 @@ case IS_DOUBLE: zend_hash_index_update(Z_ARRVAL_P(array_ptr), (long) Z_DVAL_P(offset), &expr_ptr, sizeof(zval *), NULL); break; + case IS_RESOURCE: + zend_error(E_STRICT, "Resource ID#%ld used as offset, casting to integer (%ld)", Z_LVAL_P(offset), Z_LVAL_P(offset)); + /* Fall Through */ case IS_LONG: case IS_BOOL: zend_hash_index_update(Z_ARRVAL_P(array_ptr), Z_LVAL_P(offset), &expr_ptr, sizeof(zval *), NULL);