Skip to content

Commit 143f7ee

Browse files
author
neal.norwitz
committed
This adds a leak, but fixes a crash. The leaking code is:
"{0:.{precision}s}".format('hello world', precision=5) I pretty sure it's because of the 'precision' keyword. Still need to investigate further. git-svn-id: http://svn.python.org/projects/python/branches/py3k@57548 6015fed2-1504-0410-9fe1-9d1591cc4771
1 parent 9167dee commit 143f7ee

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

Objects/stringlib/string_format.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -416,6 +416,7 @@ get_field_object(SubString *input, PyObject *args, PyObject *kwargs)
416416
Py_DECREF(key);
417417
goto error;
418418
}
419+
Py_INCREF(obj);
419420
} else {
420421
/* look up in args */
421422
obj = PySequence_GetItem(args, index);

0 commit comments

Comments
 (0)