summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorBrian Curtin <brian@python.org>2013-01-01 18:21:35 (GMT)
committerBrian Curtin <brian@python.org>2013-01-01 18:21:35 (GMT)
commite3d0b651180ddbff9198d1bf33028bce251420a9 (patch)
treec649fa46453cca286ae7990176e5620c9f0eb11b /Modules
parent950fab07aa7b0d1c664f32cd2cc3c443f816124a (diff)
downloadcpython-e3d0b651180ddbff9198d1bf33028bce251420a9.zip
cpython-e3d0b651180ddbff9198d1bf33028bce251420a9.tar.gz
cpython-e3d0b651180ddbff9198d1bf33028bce251420a9.tar.bz2
Set st_dev on Windows as unsigned long to match its DWORD type, related to the change to fix #11939.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/posixmodule.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
index e53e76c..3eec4c0 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -1955,7 +1955,8 @@ _pystat_fromstructstat(STRUCT_STAT *st)
PyStructSequence_SET_ITEM(v, 2,
PyLong_FromLongLong((PY_LONG_LONG)st->st_dev));
#else
- PyStructSequence_SET_ITEM(v, 2, PyLong_FromLong((long)st->st_dev));
+ PyStructSequence_SET_ITEM(v, 2,
+ PyLong_FromUnsignedLong(st->st_dev));
#endif
PyStructSequence_SET_ITEM(v, 3, PyLong_FromLong((long)st->st_nlink));
PyStructSequence_SET_ITEM(v, 4, PyLong_FromLong((long)st->st_uid));