summaryrefslogtreecommitdiff
path: root/Lib/threading.py
diff options
context:
space:
mode:
authorNick Coghlan <ncoghlan@gmail.com>2007-07-31 13:38:01 +0000
committerNick Coghlan <ncoghlan@gmail.com>2007-07-31 13:38:01 +0000
commit8594be3764f012e4d2967ae8e349342ea11d3764 (patch)
tree205b9e54a5e3f643ab698008401212059c055a2f /Lib/threading.py
parent9b69fb3605990489c10671856e9f7ac776c16aa2 (diff)
downloadcpython-8594be3764f012e4d2967ae8e349342ea11d3764.tar.gz
Eliminate RLock race condition reported in SF bug #1764059
Diffstat (limited to 'Lib/threading.py')
-rw-r--r--Lib/threading.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/threading.py b/Lib/threading.py
index a46090d6b2..5fc149dc33 100644
--- a/Lib/threading.py
+++ b/Lib/threading.py
@@ -85,9 +85,10 @@ class _RLock(_Verbose):
self.__count = 0
def __repr__(self):
+ owner = self.__owner
return "<%s(%s, %d)>" % (
self.__class__.__name__,
- self.__owner and self.__owner.getName(),
+ owner and owner.getName(),
self.__count)
def acquire(self, blocking=1):