php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #58022 Invalid handling of non-ascii keys on 64-bit systems
Submitted: 2008-01-30 06:50 UTC Modified: 2008-02-05 15:03 UTC
From: erikg at codepoet dot no Assigned:
Status: Duplicate Package: memcache (PECL)
PHP Version: 5.2.1 OS: ArchLinux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: erikg at codepoet dot no
New email:
PHP Version: OS:

 

 [2008-01-30 06:50 UTC] erikg at codepoet dot no
Description:
------------
On 64-bit systems, keys with non-ascii characters aren't handled correctly. The following code returns false on 32-bit systems, but "value" on 64-bit systems.

It seems like non-ascii characters are simply replaced with _.

Reproduce code:
---------------
$c = new MemCache();
$c->connect("localhost");
$c->flush();

$c->set("?", "value");
var_dump($c->get("?"));

Expected result:
----------------
false

Actual result:
--------------
"value"

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-01-30 15:02 UTC] mikael at synd dot info
This sounds like a duplicate of Bug #12883 (http://pecl.php.net/bugs/bug.php?id=12883), please checkout and try the latest source from CVS and re-open the bug if the problem persists. You can build from CVS like:

 cvs -d :pserver:cvsread@cvs.php.net:/repository co pecl/memcache
 cd pecl/memcache
 phpize
 ./configure
 make && make install

//Mikael
 [2008-02-05 08:59 UTC] erikg at codepoet dot no
Confirmed, fixed in cvs
 [2008-02-05 15:03 UTC] mikael at synd dot info
Fixed in release 2.2.3
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Jan 15 10:01:29 2025 UTC