Commit 32ba6930 authored by Vinay Sajip's avatar Vinay Sajip

Fixed execfile in pkg_resources.

--HG--
branch : distribute
extra : rebase_source : 3148f97cc98edf62e982cb14b4b90527c4fc11fb
parent 6e67978d
......@@ -41,7 +41,11 @@ except NameError:
basestring = str
from io import StringIO
exec_ = eval("exec")
def execfile(fn, globs, locs):
def execfile(fn, globs=None, locs=None):
if globs is None:
globs = globals()
if locs is None:
locs = globs
exec_(compile(open(fn).read(), fn, 'exec'), globs, locs)
# capture these to bypass sandboxing
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment