[...] > Are you aware of the standard library module 'rexec'? In fileobject.c: /* rexec.py can't stop a user from getting the file() constructor -- all they have to do is get *any* file object f, and then do type(f). Here we prevent them from doing damage with it. */ if (PyEval_GetRestricted()) { It looks like I was going to reinvent the wheel. Is this being used in some project you know about? Btw, what's the point of FileWrapper, having in mind that it stores 'f' as an accessible attribute? >>> r.s_exec("""import sys; print sys.stdout.f""") <open file '<stdout>', mode 'w' at 0x100eec30> Thank you! -- Gustavo Niemeyer [ 2AAC 7928 0FBF 0299 5EB5 60E2 2253 B29A 6664 3A0C ]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4