From: Operating system: Debian 6 PHP version: 5.3.8 Package: Unknown/Other Function Bug Type: Bug Bug description:Memcached::getByKey returns false when cas requested
Description: ------------ --- >From manual page: http://www.php.net/memcached.getbykey#refsect1- memcached.getbykey-returnvalues --- Memcached::getByKey returns false when cas requested. Test script: --------------- $mc = new Memcached('MEMCACHED_SERVER_ID'); $mc->addServer('localhost', 11211); var_dump( $mc->setByKey('server', 'key', 'set_value'), $mc->getResultMessage(), $mc->getResultCode(), '-----------------------------------', $mc->getByKey('server', 'key', null, $cas), $mc->getResultMessage(), $mc->getResultCode(), $cas, '-----------------------------------', $mc->getByKey('server', 'key'), $mc->getResultMessage(), $mc->getResultCode() ); Expected result: ---------------- bool(true) string(7) "SUCCESS" int(0) string(35) "-----------------------------------" string(9) "set_value" string(7) "SUCCESS" int(0) float(17086) string(35) "-----------------------------------" string(9) "set_value" string(7) "SUCCESS" int(0) Actual result: -------------- bool(true) string(7) "SUCCESS" int(0) string(35) "-----------------------------------" bool(false) string(7) "SUCCESS" int(0) float(17086) string(35) "-----------------------------------" string(9) "set_value" string(7) "SUCCESS" int(0) -- Edit bug report at https://bugs.php.net/bug.php?id=55818&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=55818&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=55818&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=55818&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=55818&r=fixed Fixed in SVN and need be documented: https://bugs.php.net/fix.php?id=55818&r=needdocs Fixed in release: https://bugs.php.net/fix.php?id=55818&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=55818&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=55818&r=needscript Try newer version: https://bugs.php.net/fix.php?id=55818&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=55818&r=support Expected behavior: https://bugs.php.net/fix.php?id=55818&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=55818&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=55818&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=55818&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=55818&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=55818&r=dst IIS Stability: https://bugs.php.net/fix.php?id=55818&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=55818&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=55818&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=55818&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=55818&r=mysqlcfg