summaryrefslogtreecommitdiff
path: root/Modules/_tracemalloc.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/_tracemalloc.c')
-rw-r--r--Modules/_tracemalloc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/Modules/_tracemalloc.c b/Modules/_tracemalloc.c
index 00d3542409..d9833362dd 100644
--- a/Modules/_tracemalloc.c
+++ b/Modules/_tracemalloc.c
@@ -1752,7 +1752,7 @@ _PyTraceMalloc_Init(void)
if (key == NULL)
return -1;
- value = PyDict_GetItemWithError(xoptions, key);
+ value = PyDict_GetItemWithError(xoptions, key); /* borrowed */
Py_DECREF(key);
if (value == NULL) {
if (PyErr_Occurred())
@@ -1763,7 +1763,6 @@ _PyTraceMalloc_Init(void)
}
nframe = parse_sys_xoptions(value);
- Py_DECREF(value);
if (nframe < 0) {
Py_FatalError("-X tracemalloc=NFRAME: invalid number of frames");
}