#29883 [Asn]: isset gives invalid values on strings

From: Date: Wed, 01 Dec 2004 14:03:16 +0000
Subject: #29883 [Asn]: isset gives invalid values on strings
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-69672@lists.php.net to get a copy of this message
 ID:               29883
 Updated by:       dmitry@php.net
 Reported By:      tomas_matousek at hotmail dot com
 Status:           Assigned
 Bug Type:         Zend Engine 2 problem
 Operating System: WinXP
 PHP Version:      5.0.1
 Assigned To:      andi
 New Comment:

Fixed in CVS HEAD and PHP_5_0.


Previous Comments:
------------------------------------------------------------------------

[2004-11-29 15:11:12] tony2001@php.net

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.

------------------------------------------------------------------------

[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)

« previous php.bugs (#69672) next »