Skip to content

Commit 04d042f

Browse files
author
neal.norwitz
committed
Fix uninitialized memory read reported by Valgrind when running doctest.
This could happen if size == 0. git-svn-id: http://svn.python.org/projects/python/trunk@50599 6015fed2-1504-0410-9fe1-9d1591cc4771
1 parent 6f7eed5 commit 04d042f

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

Objects/codeobject.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -556,6 +556,7 @@ PyCode_CheckLineNumber(PyCodeObject* co, int lasti, PyAddrPair *bounds)
556556
the line increments here, treating them as byte
557557
increments gets confusing, to say the least. */
558558

559+
bounds->ap_lower = 0;
559560
while (size > 0) {
560561
if (addr + *p > lasti)
561562
break;

0 commit comments

Comments
 (0)