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

HSET returns error when value is modified and shouldn't #49

Open
GoogleCodeExporter opened this issue Nov 3, 2015 · 0 comments
Open

Comments

@GoogleCodeExporter
Copy link

When trying to modify a previously set value with hset the condition


  if (rc == 0 && rhnd->reply.integer == 0)
    rc = -1;

  return rc;

Will return error. 

This is a wrong behaviour in credis lib as long as i know. 

Redis return values for hset specifies that

    rhnd->reply.integer value is 1 for new set values, and 0 for modified values.

This patch avoid that hset return error when a value is modified by hset 
function.

I have noticed same behaviour is present in zadd. Same patch can be applied to 
that function too. 

Maybe other functions are affected too.

Original issue reported on code.google.com by [email protected] on 8 May 2012 at 7:18

Attachments:

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