php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #71295 Success variable not set on wincache_ucache_get function
Submitted: 2016-01-06 16:40 UTC Modified: 2016-02-10 23:47 UTC
From: camcima at hotmail dot com Assigned: ericsten (profile)
Status: Closed Package: WinCache (PECL)
PHP Version: 7.0.1 OS: Windows 10
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: camcima at hotmail dot com
New email:
PHP Version: OS:

 

 [2016-01-06 16:40 UTC] camcima at hotmail dot com
Description:
------------
When getting a value from cache, the optional parameter $success is not being set and it stays null, for both successful and unsuccessful operations.

Test script:
---------------
<?php

$setResult = wincache_ucache_set('foo', 'bar');
$successfulGetResult = wincache_ucache_get('foo', $successShouldBeTrue);
$unsuccessfulGetResult = wincache_ucache_get('foz', $successShouldBeFalse);

echo '$setResult = ' . var_export($setResult, true) . PHP_EOL;
echo '$successfulGetResult = ' . var_export($successfulGetResult, true) . PHP_EOL;
echo '$successShouldBeTrue = ' . var_export($successShouldBeTrue, true) . PHP_EOL;
echo '$unsuccessfulGetResult = ' . var_export($unsuccessfulGetResult, true) . PHP_EOL;
echo '$successShouldBeFalse = ' . var_export($successShouldBeFalse, true) . PHP_EOL;


Expected result:
----------------
$setResult = true
$successfulGetResult = 'bar'
$successShouldBeTrue = true
$unsuccessfulGetResult = false
$successShouldBeFalse = false

Actual result:
--------------
$setResult = true
$successfulGetResult = 'bar'
$successShouldBeTrue = NULL
$unsuccessfulGetResult = false
$successShouldBeFalse = NULL

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-01-27 17:03 UTC] deivid dot garcia dot garcia at gmail dot com
This should be solved in the latest release 2.0.0.5
 [2016-02-10 23:47 UTC] ericsten@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: ericsten
 [2016-02-10 23:47 UTC] ericsten@php.net
Fixed in WinCache 2.0.0.5
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 22:01:29 2024 UTC