diff options
author | Mark Dickinson <dickinsm@gmail.com> | 2010-05-11 17:57:09 (GMT) |
---|---|---|
committer | Mark Dickinson <dickinsm@gmail.com> | 2010-05-11 17:57:09 (GMT) |
commit | e047cfa72e7916b9a5854cde9611427f7f3ef647 (patch) | |
tree | 65ebf9c28264117c86bc69a7d76c043adfb39b5a | |
parent | a467d38b91f10b7d1ad03080935f95e581692338 (diff) | |
download | cpython-e047cfa72e7916b9a5854cde9611427f7f3ef647.zip cpython-e047cfa72e7916b9a5854cde9611427f7f3ef647.tar.gz cpython-e047cfa72e7916b9a5854cde9611427f7f3ef647.tar.bz2 |
Issue #8677: Make curses module PY_SSIZE_T_CLEAN.
-rw-r--r-- | Modules/_cursesmodule.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Modules/_cursesmodule.c b/Modules/_cursesmodule.c index 442c3f1..0172b32 100644 --- a/Modules/_cursesmodule.c +++ b/Modules/_cursesmodule.c @@ -100,6 +100,8 @@ char *PyCursesVersion = "2.2"; /* Includes */ +#define PY_SSIZE_T_CLEAN + #include "Python.h" @@ -1382,7 +1384,7 @@ PyCursesWindow_PutWin(PyCursesWindowObject *self, PyObject *stream) fseek(fp, 0, 0); while (1) { char buf[BUFSIZ]; - int n = fread(buf, 1, BUFSIZ, fp); + Py_ssize_t n = fread(buf, 1, BUFSIZ, fp); if (n <= 0) break; Py_DECREF(res); |