summaryrefslogtreecommitdiff
path: root/Python/errors.c
diff options
context:
space:
mode:
Diffstat (limited to 'Python/errors.c')
-rw-r--r--Python/errors.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Python/errors.c b/Python/errors.c
index 4656fb2a33..a2fe52b812 100644
--- a/Python/errors.c
+++ b/Python/errors.c
@@ -5,6 +5,7 @@
#include "pycore_initconfig.h"
#include "pycore_pyerrors.h"
#include "pycore_pystate.h"
+#include "pycore_sysmodule.h"
#include "pycore_traceback.h"
#ifndef __STDC__
@@ -1410,7 +1411,7 @@ _PyErr_WriteUnraisableMsg(const char *err_msg_str, PyObject *obj)
goto default_hook;
}
- if (PySys_Audit("sys.unraisablehook", "OO", hook, hook_args) < 0) {
+ if (_PySys_Audit(tstate, "sys.unraisablehook", "OO", hook, hook_args) < 0) {
Py_DECREF(hook_args);
err_msg_str = "Exception ignored in audit hook";
obj = NULL;