diff Python/errors.c @ 65482:38ad57db88ac

PyErr_SyntaxLocationEx() uses PyUnicode_DecodeFSDefault(), instead of PyUnicode_FromString(), to decode the filename.
author Victor Stinner <victor.stinner@haypocalc.com>
date Sun, 17 Oct 2010 19:03:16 +0000
parents 00e4ce31d404
children 39b9e9de372b
line wrap: on
line diff
--- a/Python/errors.c	Sun Oct 17 18:59:56 2010 +0000
+++ b/Python/errors.c	Sun Oct 17 19:03:16 2010 +0000
@@ -819,7 +819,7 @@
         }
     }
     if (filename != NULL) {
-        tmp = PyUnicode_FromString(filename);
+        tmp = PyUnicode_DecodeFSDefault(filename);
         if (tmp == NULL)
             PyErr_Clear();
         else {