'valgrind python' shows numerous free'd memory accesses during initialization
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
python-defaults (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
I run 'valgrind python </dev/null' and get numerous memory access errors from valgrind.
E.g.:
$ valgrind --suppressions=
==23585== Memcheck, a memory error detector
==23585== Copyright (C) 2002-2011, and GNU GPL'd, by Julian Seward et al.
==23585== Using Valgrind-3.7.0 and LibVEX; rerun with -h for copyright info
==23585== Command: python
==23585==
==23585== Invalid read of size 4
==23585== at 0x5740EF: PyObject_Free (in /usr/bin/python2.7)
==23585== by 0x45B9A6: code_dealloc.9725 (in /usr/bin/python2.7)
==23585== by 0x55F6EF: load_source_
==23585== by 0x5600CA: import_
==23585== by 0x4A0892: load_next.39111 (in /usr/bin/python2.7)
==23585== by 0x560963: import_
==23585== by 0x553EAA: builtin_
==23585== by 0x4BF2A5: PyObject_Call (in /usr/bin/python2.7)
==23585== by 0x4BF5A5: PyEval_
==23585== by 0x46870A: PyEval_EvalFrameEx (in /usr/bin/python2.7)
==23585== by 0x57BD01: PyEval_EvalCodeEx (in /usr/bin/python2.7)
==23585== by 0x57CDA7: PyImport_
==23585== Address 0x6694020 is 0 bytes inside a block of size 568 free'd
==23585== at 0x4C2A82E: free (in /usr/lib/
==23585== by 0x6010814: fclose@@GLIBC_2.2.5 (iofclose.c:88)
==23585== by 0x55F683: load_source_
==23585== by 0x5600CA: import_
==23585== by 0x4A0892: load_next.39111 (in /usr/bin/python2.7)
==23585== by 0x560963: import_
==23585== by 0x553EAA: builtin_
==23585== by 0x4BF2A5: PyObject_Call (in /usr/bin/python2.7)
==23585== by 0x4BF5A5: PyEval_
==23585== by 0x46870A: PyEval_EvalFrameEx (in /usr/bin/python2.7)
==23585== by 0x57BD01: PyEval_EvalCodeEx (in /usr/bin/python2.7)
==23585== by 0x57CDA7: PyImport_
==23585==
It is not a false positive of subtle low-level memory access of python as it is an invalid access from glibc's function, not a python internal function.
The full valgrind output is uploaded here: http://
ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: python 2.7.3-0ubuntu2.2
ProcVersionSign
Uname: Linux 3.2.0-54-generic x86_64
ApportVersion: 2.0.1-0ubuntu17.4
Architecture: amd64
CheckboxSubmission: 8cd6ce4bf8fb309
CheckboxSystem: b633b4f40868d49
Date: Sat Sep 28 15:48:47 2013
EcryptfsInUse: Yes
InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Release amd64 (20120425)
MarkForUpload: True
SourcePackage: python-defaults
UpgradeStatus: No upgrade log present (probably fresh install)