summaryrefslogtreecommitdiffstats
path: root/Modules/stropmodule.c
diff options
context:
space:
mode:
authorMartin v. Löwis <martin@v.loewis.de>2006-04-13 07:34:09 (GMT)
committerMartin v. Löwis <martin@v.loewis.de>2006-04-13 07:34:09 (GMT)
commit2308915b2f3114a592e51053ca788dcb7d0a2541 (patch)
treead2e279aaf785f8a80f8347d2dccad1819615bc9 /Modules/stropmodule.c
parent635af32bdfd0bb002d37b7dcb148d8f18c1438cc (diff)
downloadcpython-2308915b2f3114a592e51053ca788dcb7d0a2541.zip
cpython-2308915b2f3114a592e51053ca788dcb7d0a2541.tar.gz
cpython-2308915b2f3114a592e51053ca788dcb7d0a2541.tar.bz2
Replace INT_MAX with PY_SSIZE_T_MAX.
Diffstat (limited to 'Modules/stropmodule.c')
-rw-r--r--Modules/stropmodule.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/Modules/stropmodule.c b/Modules/stropmodule.c
index c1ad43a..8b00fed 100644
--- a/Modules/stropmodule.c
+++ b/Modules/stropmodule.c
@@ -333,7 +333,7 @@ strop_rfind(PyObject *self, PyObject *args)
{
char *s, *sub;
Py_ssize_t len, n, j;
- Py_ssize_t i = 0, last = INT_MAX;
+ Py_ssize_t i = 0, last = PY_SSIZE_T_MAX;
WARN;
if (!PyArg_ParseTuple(args, "t#t#|nn:rfind", &s, &len, &sub, &n, &i, &last))
@@ -647,7 +647,7 @@ strop_count(PyObject *self, PyObject *args)
{
char *s, *sub;
Py_ssize_t len, n;
- Py_ssize_t i = 0, last = INT_MAX;
+ Py_ssize_t i = 0, last = PY_SSIZE_T_MAX;
Py_ssize_t m, r;
WARN;
@@ -1078,7 +1078,7 @@ mymemreplace(const char *str, Py_ssize_t len, /* input string */
/* find length of output string */
nfound = mymemcnt(str, len, pat, pat_len);
if (count < 0)
- count = INT_MAX;
+ count = PY_SSIZE_T_MAX;
else if (nfound > count)
nfound = count;
if (nfound == 0)