summaryrefslogtreecommitdiffstats
path: root/Modules/posixmodule.c
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2013-06-03 20:09:14 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2013-06-03 20:09:14 (GMT)
commit0b81111b18790e5d95cb84a09d15aadfb8a1dadf (patch)
tree221dc022b26c5cf993e825537aabfd7dab36adba /Modules/posixmodule.c
parent725e4212229bf68f87d4f66c1815d444ddfc7aa5 (diff)
parenta534fc4b3bd4b731be9304be626bc161f53d7bfb (diff)
downloadcpython-0b81111b18790e5d95cb84a09d15aadfb8a1dadf.zip
cpython-0b81111b18790e5d95cb84a09d15aadfb8a1dadf.tar.gz
cpython-0b81111b18790e5d95cb84a09d15aadfb8a1dadf.tar.bz2
(Merge 3.3) Close #18109: os.uname() now decodes fields from the locale
encoding, and socket.gethostname() now decodes the hostname from the locale encoding, instead of using the UTF-8 encoding in strict mode.
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 90bbb13..17a9611 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -4257,7 +4257,7 @@ posix_uname(PyObject *self, PyObject *noargs)
#define SET(i, field) \
{ \
- PyObject *o = PyUnicode_DecodeASCII(field, strlen(field), NULL); \
+ PyObject *o = PyUnicode_DecodeFSDefault(field); \
if (!o) { \
Py_DECREF(value); \
return NULL; \