[Python-checkins] cpython: Issue #9566: _io: Use Py_SAFE_DOWNCAST for fix a compiler warning on Windows x64

victor.stinner python-checkins at python.org
Mon Jun 24 23:05:20 CEST 2013


http://hg.python.org/cpython/rev/5c407b64920c
changeset:   84319:5c407b64920c
user:        Victor Stinner <victor.stinner at gmail.com>
date:        Mon Jun 24 23:01:33 2013 +0200
summary:
  Issue #9566: _io: Use Py_SAFE_DOWNCAST for fix a compiler warning on Windows x64

files:
  Modules/_io/textio.c |  2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)


diff --git a/Modules/_io/textio.c b/Modules/_io/textio.c
--- a/Modules/_io/textio.c
+++ b/Modules/_io/textio.c
@@ -2347,7 +2347,7 @@
 
     /* Note our initial start point. */
     cookie.start_pos += skip_bytes;
-    cookie.chars_to_skip = chars_to_skip;
+    cookie.chars_to_skip = Py_SAFE_DOWNCAST(chars_to_skip, Py_ssize_t, int);
     if (chars_to_skip == 0)
         goto finally;
 

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list