summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2018-08-08 04:51:12 (GMT)
committerGitHub <noreply@github.com>2018-08-08 04:51:12 (GMT)
commit52dee687af3671a31f63d6432de0d9ef370fd7b0 (patch)
tree4c67de721e32289e5488c36dd48147293097192b /Lib
parentdb8707c8ab57d9454c838586c08199c82a3d74d9 (diff)
downloadcpython-52dee687af3671a31f63d6432de0d9ef370fd7b0.zip
cpython-52dee687af3671a31f63d6432de0d9ef370fd7b0.tar.gz
cpython-52dee687af3671a31f63d6432de0d9ef370fd7b0.tar.bz2
Assume the raw environ is always declared. (GH-8707)
posixmodule.c always declares environ, so don't bother catching a NameError in os.py.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/os.py6
1 files changed, 0 insertions, 6 deletions
diff --git a/Lib/os.py b/Lib/os.py
index 499e628..4b31e4d 100644
--- a/Lib/os.py
+++ b/Lib/os.py
@@ -525,12 +525,6 @@ if {open, stat} <= supports_dir_fd and {scandir, stat} <= supports_fd:
__all__.append("fwalk")
-# Make sure os.environ exists, at least
-try:
- environ
-except NameError:
- environ = {}
-
def execl(file, *args):
"""execl(file, *args)