gh-119431: fix refleak in test_monitoring (#119444)

This commit is contained in:
Irit Katriel 2024-05-23 05:21:53 -04:00 committed by GitHub
parent e3f5a44553
commit c85e352673
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 0 deletions

View File

@ -2724,5 +2724,6 @@ _PyMonitoring_FireStopIterationEvent(PyMonitoringState *state, PyObject *codelik
}
PyObject *args[4] = { NULL, NULL, NULL, exc };
int err = capi_call_instrumentation(state, codelike, offset, args, 3, event);
Py_DECREF(exc);
return exception_event_teardown(err, NULL);
}