classification
Title: dictionary views lead to segmentation fault
Type: crash Stage: resolved
Components: Versions: Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: Marcin.Szamotulski, python-dev
Priority: normal Keywords:

Created on 2013-05-20 02:18 by Marcin.Szamotulski, last changed 2013-05-20 02:39 by python-dev. This issue is now closed.

Messages (2)
msg189632 - (view) Author: Marcin Szamotulski (Marcin.Szamotulski) Date: 2013-05-20 02:18
This simple snipet will crash python:
>>> d={}
>>> v=d.viewvalues()
>>> k=d.viewkeys()
>>> d[v]=k
>>> k
Segmentation fault

I am using python2.7.  Python3.2 does not have views while .keys() and .values() methods raise RuntimeError: maximum recursion depth exceeded, which is expected.
msg189635 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2013-05-20 02:39
New changeset 3568f8f1ccac by Benjamin Peterson in branch '2.7':
add missing NULL check (closes #18019)
http://hg.python.org/cpython/rev/3568f8f1ccac
History
Date User Action Args
2013-05-20 02:39:53python-devsetstatus: open -> closed

nosy: + python-dev
messages: + msg189635

resolution: fixed
stage: resolved
2013-05-20 02:18:42Marcin.Szamotulskicreate