php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72980 APCu: apcu_fetch() fails to return empty key value
Submitted: 2016-08-30 16:06 UTC Modified: 2016-11-18 20:57 UTC
From: vedad at kajtaz dot net Assigned:
Status: Open Package: APC (PECL)
PHP Version: 7.0.10 OS: FreeBSD 10.1
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2016-08-30 16:06 UTC] vedad at kajtaz dot net
Description:
------------
This bug report is related to the apcu 5.1.5 (the bug sumbittion form only provided 'APC' choice).

apcu_fetch('') fails to return empty string key value previously set with apcu_store('', ...). On the other hand, apcu_fetch(['']) does.

Test script:
---------------
echo apcu_store('', 'empty') ? 'stored' : 'not stored';
echo PHP_EOL;
var_export(apcu_fetch(''));
var_export(apcu_fetch(['']));


Expected result:
----------------
stored
'empty'
array (
  '' => 'empty',
)


Actual result:
--------------
stored
false
array (
  '' => 'empty',
)

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-11-18 20:57 UTC] kalle@php.net
-Summary: apcu_fetch() fails to return empty key value +Summary: APCu: apcu_fetch() fails to return empty key value
 
PHP Copyright © 2001-2017 The PHP Group
All rights reserved.
Last updated: Sun Nov 19 01:31:42 2017 UTC