summaryrefslogtreecommitdiffstats
path: root/Lib/os.py
diff options
context:
space:
mode:
authorRichard Oudkerk <shibturn@gmail.com>2013-05-07 13:36:51 (GMT)
committerRichard Oudkerk <shibturn@gmail.com>2013-05-07 13:36:51 (GMT)
commitc41917f4cb1287cddd36b78079a051bda6c42e40 (patch)
treeff97289ffc7768c33c9c2a20ce781dd9ab9de1c9 /Lib/os.py
parentad34ef8640dfed63d84d0e71d7f75308cf28641f (diff)
downloadcpython-c41917f4cb1287cddd36b78079a051bda6c42e40.zip
cpython-c41917f4cb1287cddd36b78079a051bda6c42e40.tar.gz
cpython-c41917f4cb1287cddd36b78079a051bda6c42e40.tar.bz2
Correction for 4f82b6cfee46.
Diffstat (limited to 'Lib/os.py')
-rw-r--r--Lib/os.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/Lib/os.py b/Lib/os.py
index 7ab28d4..96720e4 100644
--- a/Lib/os.py
+++ b/Lib/os.py
@@ -686,16 +686,21 @@ class _Environ(MutableMapping):
self[key] = value
return self[key]
-# if putenv or unsetenv exist they should already be in __all__
try:
_putenv = putenv
except NameError:
_putenv = lambda key, value: None
+else:
+ if "putenv" not in __all__:
+ __all__.append("putenv")
try:
_unsetenv = unsetenv
except NameError:
_unsetenv = lambda key: _putenv(key, "")
+else:
+ if "unsetenv" not in __all__:
+ __all__.append("unsetenv")
def _createenviron():
if name == 'nt':