Ticket #16358: memcached.py.patch
File memcached.py.patch, 640 bytes (added by , 13 years ago) |
---|
-
memcached.py
old new 62 62 63 63 def set(self, key, value, timeout=0, version=None): 64 64 key = self.make_key(key, version=version) 65 self._cache.set(key, value, self._get_memcache_timeout(timeout)) 65 if not self._cache.set(key, value, self._get_memcache_timeout(timeout)): 66 self._cache.delete(key) # make sure the key doesn't keep its old value in case of failure to set (memcached's 1MB limit) 66 67 67 68 def delete(self, key, version=None): 68 69 key = self.make_key(key, version=version)