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

auto_response sets value to garbage if rc=NOT_FOUND #24

Closed
m6w6 opened this issue Jan 20, 2020 · 2 comments
Closed

auto_response sets value to garbage if rc=NOT_FOUND #24

m6w6 opened this issue Jan 20, 2020 · 2 comments

Comments

@m6w6
Copy link
Collaborator

m6w6 commented Jan 20, 2020

Imported from Launchpad using lp2gh.


auto_response executes *value= instance->root->result.numeric_value; even when rc == NOT_FOUND.

The http://docs.libmemcached.org/memcached_auto.html docs only describe "If the object specified by key does not exist" behaviour for the memcached_with_initial variants. However the memcached_with_initial variants can't be used with the textual protocol (but that's not mentioned in the docs.)

(This caused a failure in Cache::Memcached::libmemcached https://rt.cpan.org/Ticket/Display.html?id=88376)

@m6w6 m6w6 added the New label Jan 20, 2020
@m6w6
Copy link
Collaborator Author

m6w6 commented Jan 20, 2020


if (memcached_fatal(rc) or memcached_failed(rc))
{
assert(memcached_last_error(instance->root) != MEMCACHED_SUCCESS);
*value= UINT64_MAX;
}

@m6w6 m6w6 removed the New label Jan 20, 2020
@m6w6
Copy link
Collaborator Author

m6w6 commented Jan 21, 2020

Fixed in dd1ce96

@m6w6 m6w6 closed this as completed Jan 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant