php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #69809 memcache get always modify flag parameter
Submitted: 2015-06-12 09:50 UTC Modified: 2021-03-25 16:38 UTC
From: bburnichon at gmail dot com Assigned: cmb (profile)
Status: Closed Package: memcache (PECL)
PHP Version: 5.5.26 OS: Mac OS X
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: bburnichon at gmail dot com
New email:
PHP Version: OS:

 

 [2015-06-12 09:50 UTC] bburnichon at gmail dot com
Description:
------------
In an application I'm in charge of, some booleans are cached, The only way to know whether false returned is an actual hit is to check whether the flag value was changed.

It works perfectly on a vagrant debian 7 but not in native OSX installation.

memcache

memcache support => enabled
Active persistent connections => 0
Version => 2.2.7
Revision => $Revision: 327750 $

Directive => Local Value => Master Value
memcache.allow_failover => 1 => 1
memcache.chunk_size => 8192 => 8192
memcache.default_port => 11211 => 11211
memcache.default_timeout_ms => 1000 => 1000
memcache.hash_function => crc32 => crc32
memcache.hash_strategy => standard => standard
memcache.max_failover_attempts => 20 => 20


Test script:
---------------
$memcache = new Memcache();
$memcache->connect('localhost', 11211);
$memcache->flush();
$flag = null; var_dump($memcache->get('foo', $flag), $flag);


Expected result:
----------------
bool(false)
NULL

Actual result:
--------------
bool(false)
int(0)

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2021-03-25 16:38 UTC] cmb@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: cmb
 [2021-03-25 16:38 UTC] cmb@php.net
The official bug tracker for PECL/memcache is now at
<https://github.com/websupport-sk/pecl-memcache/issues>.

So, if this is still an issue with either of the current memcache
versions (4 or 8), please file an issue there.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 24 22:01:30 2024 UTC