summaryrefslogtreecommitdiffstats
path: root/Modules/posixmodule.c
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@haypocalc.com>2010-05-07 16:34:53 (GMT)
committerVictor Stinner <victor.stinner@haypocalc.com>2010-05-07 16:34:53 (GMT)
commit97c18ab6a52774364511bb5e4bf0444af4e700b9 (patch)
tree5e14ba30e2d38f4813d027b4a391460d8fdfcc85 /Modules/posixmodule.c
parent56fdb7545363c5b1e2987b08fa9b271dd289ce66 (diff)
downloadcpython-97c18ab6a52774364511bb5e4bf0444af4e700b9.zip
cpython-97c18ab6a52774364511bb5e4bf0444af4e700b9.tar.gz
cpython-97c18ab6a52774364511bb5e4bf0444af4e700b9.tar.bz2
Replace PyUnicode_Decode(buf, strlen(buf), Py_FileSystemDefaultEncoding,
"surrogateescape") by PyUnicode_DecodeFSDefault(val).
Diffstat (limited to 'Modules/posixmodule.c')
-rw-r--r--Modules/posixmodule.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
index 0d6f8f0..a48f233 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -2031,7 +2031,7 @@ posix_getcwd(int use_bytes)
return posix_error();
if (use_bytes)
return PyBytes_FromStringAndSize(buf, strlen(buf));
- return PyUnicode_Decode(buf, strlen(buf), Py_FileSystemDefaultEncoding,"surrogateescape");
+ return PyUnicode_DecodeFSDefault(buf);
}
PyDoc_STRVAR(posix_getcwd__doc__,