forked from redis/redis-py
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Lock.release(): reorder code to avoid token overwrite
* assignment to self.token was not protected by the lock, so the value could get overwritten * do_release() now has an expected_token parameter that receives the old token value * NOTE: this only fixes the issue for locks that do not have timeouts
- Loading branch information
1 parent
e7589d7
commit 643d76d
Showing
1 changed file
with
7 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters