From 725f8c83a27989ea2413c6d9c824cb78eddf52dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20v=2E=20L=C3=B6wis?= Date: Sat, 18 Sep 2004 16:07:58 +0000 Subject: Patch #1021596: Check for None to determine whether _urandomfd is uninitialized. --- Lib/os.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/os.py b/Lib/os.py index 20746e8..8839c10 100644 --- a/Lib/os.py +++ b/Lib/os.py @@ -666,7 +666,7 @@ if not _exists("urandom"): """ global _urandomfd - if not _urandomfd: + if _urandomfd is None: try: _urandomfd = open("/dev/urandom", O_RDONLY) except: -- cgit v0.12