From 60419a7e96577cf783b3b45bf3984f9fb0d7ddff Mon Sep 17 00:00:00 2001 From: Steve Dower Date: Mon, 24 Jun 2019 08:42:54 -0700 Subject: bpo-37363: Add audit events for a range of modules (GH-14301) --- Python/bltinmodule.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'Python/bltinmodule.c') diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c index ae2a5187d9..90fbb44882 100644 --- a/Python/bltinmodule.c +++ b/Python/bltinmodule.c @@ -482,6 +482,11 @@ builtin_breakpoint(PyObject *self, PyObject *const *args, Py_ssize_t nargs, PyOb PyErr_SetString(PyExc_RuntimeError, "lost sys.breakpointhook"); return NULL; } + + if (PySys_Audit("builtins.breakpoint", "O", hook) < 0) { + return NULL; + } + Py_INCREF(hook); PyObject *retval = _PyObject_Vectorcall(hook, args, nargs, keywords); Py_DECREF(hook); -- cgit v1.2.1