#37176 [Fbk->Csd]: iconv_strpos fails to find a string

From: Date: Mon, 01 May 2006 14:12:54 +0000
Subject: #37176 [Fbk->Csd]: iconv_strpos fails to find a string
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-96418@lists.php.net to get a copy of this message
ID: 37176 User updated by: lana0 at zahav dot net dot il Reported By: lana0 at zahav dot net dot il -Status: Feedback +Status: Closed Bug Type: ICONV related Operating System: XP SP2 PHP Version: 5.1.2 Assigned To: moriyoshi New Comment: I see now it works right. Previous Comments: ------------------------------------------------------------------------ [2006-04-28 05:12:31] moriyoshi@php.net Please try using this CVS snapshot: http://snaps.php.net/php5.1-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.1-win32-latest.zip ------------------------------------------------------------------------ [2006-04-24 19:52:35] tony2001@php.net Assigned to the maintainer. ------------------------------------------------------------------------ [2006-04-24 02:26:54] lana0 at zahav dot net dot il Description: ------------ The next statements return FALSE (and should return 1): echo iconv_strpos('11--','1-',0,'UTF-8'); echo iconv_strpos('-11--','1-',0,'UTF-8'); .i.e it fails if the first char of a searched string comes doubled in parsed one. Reproduce code: --------------- echo iconv_strpos('11--','1-',0,'UTF-8'); echo iconv_strpos('-11--','1-',0,'UTF-8'); Expected result: ---------------- 1 2 Actual result: -------------- FALSE FALSE ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=37176&edit=1

« previous php.bugs (#96418) next »