#29883 [Opn->Asn]: isset gives invalid values on strings
ID: 29883
Updated by: tony2001@php.net
Reported By: tomas_matousek at hotmail dot com
-Status: Open
+Status: Assigned
-Bug Type: Scripting Engine problem
+Bug Type: Zend Engine 2 problem
Operating System: WinXP
PHP Version: 5.0.1
-Assigned To:
+Assigned To: andi
New Comment:
Andi, please, review & commit these two patches:
http://tony2001.phpclub.net/dev/tmp/bug29883_5_0.diff
http://tony2001.phpclub.net/dev/tmp/bug29883_HEAD.diff
The bug really affects BC issues and should have been fixed long ago
IMO.
Previous Comments:
------------------------------------------------------------------------
[2004-08-29 13:11:15] tomas_matousek at hotmail dot com
Description:
------------
isset applied on a string with negative index returns true.
It should return false.
Reproduce code:
---------------
$x = "bug";
var_dump(isset($x[-1]));
Expected result:
----------------
bool(false)
Actual result:
--------------
bool(true)
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=29883&edit=1
Thread (4 messages)