diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2015-01-26 15:43:36 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2015-01-26 15:43:36 (GMT) |
commit | 5474d0ba19e7fadf98440369216b0b66d6b7e647 (patch) | |
tree | de088b3d531c3254fecca0ab21df79e7cbd4a6c8 /Objects/bytesobject.c | |
parent | 29dacf2e97314a16db3f2bef492d1c46f39ad656 (diff) | |
download | cpython-5474d0ba19e7fadf98440369216b0b66d6b7e647.zip cpython-5474d0ba19e7fadf98440369216b0b66d6b7e647.tar.gz cpython-5474d0ba19e7fadf98440369216b0b66d6b7e647.tar.bz2 |
Issue #20284: Fix a compilation warning on Windows
Explicitly cast the long to char.
Diffstat (limited to 'Objects/bytesobject.c')
-rw-r--r-- | Objects/bytesobject.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/bytesobject.c b/Objects/bytesobject.c index 154640e..d4f7d01 100644 --- a/Objects/bytesobject.c +++ b/Objects/bytesobject.c @@ -529,7 +529,7 @@ formatchar(char *buf, size_t buflen, PyObject *v) "%c requires an integer in range(256) or a single byte"); goto error; } - buf[0] = ival; + buf[0] = (char)ival; } Py_XDECREF(w); buf[1] = '\0'; |