From: Richard Oudkerk Date: Tue, 7 May 2013 13:36:51 +0000 (+0100) Subject: Correction for 4f82b6cfee46. X-Git-Tag: v3.4.0a1~772 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c41917f4cb1287cddd36b78079a051bda6c42e40;p=thirdparty%2FPython%2Fcpython.git Correction for 4f82b6cfee46. --- diff --git a/Lib/os.py b/Lib/os.py index 7ab28d4f90e3..96720e41ef81 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':