Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to set new data using Memcache API #26

Open
GoogleCodeExporter opened this issue Mar 27, 2015 · 0 comments
Open

Unable to set new data using Memcache API #26

GoogleCodeExporter opened this issue Mar 27, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. Navigate to /commands.php
2. In 'Execute predefined Command', choose the 'set' command.
3. Enter any key and value.
4. Choose 'Memcache' for API.

What is the expected output? What do you see instead?
In the console I expect:

Server 127.0.0.1:11211
SUCCESS

Instead, I receive a warning:

( ! ) Warning: Memcache::set() expects parameter 4 to be long, string given in 
/path/to/phpmemcachedadmin/phpMemcachedAdmin-1.2.2-r262/Library/Command/Memcache
.php on line 191

What version of the product are you using? On what operating system?
- phpmemcachedadmin 1.2.2-r262
- Mac OS X 10.9.3
- PHP Version 5.4.24
- Apache/2.2.26 (Unix)

Please provide any additional information below.

Library/Command/Memcache.php, line 191 is currently:

if(self::$_memcache->set($key, $data, 0, $duration))

It's missing some type casting, and should be:

if(self::$_memcache->set($key, $data, 0, (int) $duration))

Original issue reported on code.google.com by ja...@jamesmcfadden.co.uk on 27 May 2014 at 3:57

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant