Commit cc546226 authored by Benjamin Peterson's avatar Benjamin Peterson

remove more code for restricted execution

parent f6348f45
...@@ -66,15 +66,10 @@ XRangeType = xrange ...@@ -66,15 +66,10 @@ XRangeType = xrange
try: try:
raise TypeError raise TypeError
except TypeError: except TypeError:
try:
tb = sys.exc_info()[2] tb = sys.exc_info()[2]
TracebackType = type(tb) TracebackType = type(tb)
FrameType = type(tb.tb_frame) FrameType = type(tb.tb_frame)
except AttributeError: del tb
# In the restricted environment, exc_info returns (None, None,
# None) Then, tb.tb_frame gives an attribute error
pass
tb = None; del tb
SliceType = slice SliceType = slice
EllipsisType = type(Ellipsis) EllipsisType = type(Ellipsis)
......
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