summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@haypocalc.com>2010-10-17 19:03:16 (GMT)
committerVictor Stinner <victor.stinner@haypocalc.com>2010-10-17 19:03:16 (GMT)
commit15a71cdad2537b9ffcfe7216ea9af61d7888db98 (patch)
treee5da97ff783800b3d8fbc7393f6bdc8d58f0abc8 /Python
parent5b5d8d58c76cac7c1e3bdc8004abad137ee8d3ce (diff)
downloadcpython-15a71cdad2537b9ffcfe7216ea9af61d7888db98.zip
cpython-15a71cdad2537b9ffcfe7216ea9af61d7888db98.tar.gz
cpython-15a71cdad2537b9ffcfe7216ea9af61d7888db98.tar.bz2
PyErr_SyntaxLocationEx() uses PyUnicode_DecodeFSDefault(), instead of
PyUnicode_FromString(), to decode the filename.
Diffstat (limited to 'Python')
-rw-r--r--Python/errors.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/errors.c b/Python/errors.c
index a24095d..e3486b9 100644
--- a/Python/errors.c
+++ b/Python/errors.c
@@ -819,7 +819,7 @@ PyErr_SyntaxLocationEx(const char *filename, int lineno, int col_offset)
}
}
if (filename != NULL) {
- tmp = PyUnicode_FromString(filename);
+ tmp = PyUnicode_DecodeFSDefault(filename);
if (tmp == NULL)
PyErr_Clear();
else {