summaryrefslogtreecommitdiffstats
path: root/Python/_warnings.c
diff options
context:
space:
mode:
Diffstat (limited to 'Python/_warnings.c')
-rw-r--r--Python/_warnings.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/Python/_warnings.c b/Python/_warnings.c
index 793cbc6..17404d3 100644
--- a/Python/_warnings.c
+++ b/Python/_warnings.c
@@ -569,10 +569,9 @@ call_show_warning(PyThreadState *tstate, PyObject *category,
PyObject *show_fn, *msg, *res, *warnmsg_cls = NULL;
PyInterpreterState *interp = tstate->interp;
- /* If the source parameter is set, try to get the Python implementation.
- The Python implementation is able to log the traceback where the source
+ /* The Python implementation is able to log the traceback where the source
was allocated, whereas the C implementation doesn't. */
- show_fn = GET_WARNINGS_ATTR(interp, _showwarnmsg, source != NULL);
+ show_fn = GET_WARNINGS_ATTR(interp, _showwarnmsg, 1);
if (show_fn == NULL) {
if (PyErr_Occurred())
return -1;