GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||
GeezerVison is showing github.com — iter `__reduce__` can segfault if accessing `__builtins__.__dict__['iter']` mutates the iter object · Issue #101765 · python/cpython Closed Labels interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)type-crashA hard crash of the interpreter, possibly with a core dumpA hard crash of the interpreter, possibly with a core dump DescriptionCrash reportExample from @chilaxan corrupt = iter(lambda:0, 0) class Cstr: def __hash__(self): return hash('iter') def __eq__(self, other): [*corrupt] return other == 'iter' builtins = __builtins__.__dict__ if hasattr(__builtins__, '__dict__') else __builtins__ oiter = builtins['iter'] del builtins['iter'] builtins[Cstr()] = oiter print(corrupt.__reduce__()) Expected resultThis should return a valid Error messages
Windows fatal exception: access violation > exit code -1073741819 (0xC0000005)
print(corrupt.__reduce__()) ^^^^^^^^^^^^^^^^^^^^ SystemError: NULL object passed to Py_BuildValue
(<built-in function iter>, (<function at 0x7fb772c3c4a0>, 0)) > terminated by signal SIGSEGV (Address boundary error)
(<built-in function iter>, (<function at 0x7f3480d71f80>, 0))
Fatal Python error: Segmentation fault Linked PRs
Activity
MetadataMetadataAssigneesLabelsinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)type-crashA hard crash of the interpreter, possibly with a core dumpA hard crash of the interpreter, possibly with a core dump ProjectsMilestoneRelationshipsDevelopmentIssue actions | ||||
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |