nightdomain / jmemcache-daemon

Automatically exported from code.google.com/p/jmemcache-daemon
Apache License 2.0
0 stars 0 forks source link

cas does not work correctly #23

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Issue occurs only in current version. It was working with 0.8.

set creates a new unique-id for a cacheelement, but cas does not. so for every 
cacheelement set with cas, the unique-id is always 0.

To reproduce connect with telnet and do the following:

> set foo 0 0 3
> bar
< STORED
> gets foo
< VALUE foo 0 3 3984
< bar
< END
> cas foo 0 0 3 3984
> baz
< STORED
> gets foo
< VALUE foo 0 3 0              <-- it's 0, ok if it would happen just once
< baz
< END
> cas foo 0 0 3 0
> wup
< STORED
> gets foo
< VALUE foo 0 3 0              <-- oops, there it is again
< wup
< END

The attached patch fixes it issue.

Original issue reported on code.google.com by marcus.h...@gmail.com on 13 Dec 2010 at 2:04

Attachments:

GoogleCodeExporter commented 9 years ago
Patch applied and committed.

Original comment by ryan.daum on 10 Jan 2011 at 6:14