summaryrefslogtreecommitdiff
path: root/Python/pythonrun.c
diff options
context:
space:
mode:
Diffstat (limited to 'Python/pythonrun.c')
-rw-r--r--Python/pythonrun.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/pythonrun.c b/Python/pythonrun.c
index f95ea831aa..faacb447d2 100644
--- a/Python/pythonrun.c
+++ b/Python/pythonrun.c
@@ -1103,7 +1103,7 @@ parse_syntax_error(PyObject *err, PyObject **message, const char **filename,
goto finally;
if (v == Py_None)
*filename = NULL;
- else if (! (*filename = PyString_AsString(v)))
+ else if (! (*filename = PyUnicode_AsString(v)))
goto finally;
Py_DECREF(v);