[issue19888] possible memory corruption caused by for-loop iteration over namespace.items() in a metaclass defining __new__

Zygmunt Krynicki report at bugs.python.org
Wed Dec 4 23:06:07 CET 2013


New submission from Zygmunt Krynicki:

It seems that a particular code sequence causes memory corruption (but not a crash so far) in the interpreter. I've attached a test case that fails assertion on python3.2 (tested on current amd64 12.04 builds) and works on python3.3 (tested on current amd64 14.04 builds and i386 fedora 19 builds).

The attached test program shows how the bug is actually triggered by using a for loop to iterate over key, value in namespace.items() inside a metaclass __new__() method that does nothing else apart from that.

----------
components: Interpreter Core
files: bug.py
messages: 205250
nosy: zkrynicki
priority: normal
severity: normal
status: open
title: possible memory corruption caused by for-loop iteration over namespace.items() in a metaclass defining __new__
type: security
versions: Python 3.2
Added file: http://bugs.python.org/file32975/bug.py

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue19888>
_______________________________________


More information about the Python-bugs-list mailing list