From 481ac8811e41f509e3a4ca6ef0151ce69671b43e Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Fri, 19 Mar 1999 21:50:11 +0000 Subject: Use an unsigned cast to avoid a warning in VC++. --- Modules/arraymodule.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Modules/arraymodule.c b/Modules/arraymodule.c index bb0a9ed..8bd9a55 100644 --- a/Modules/arraymodule.c +++ b/Modules/arraymodule.c @@ -939,7 +939,8 @@ array_fromfile(self, args) size_t newbytes; /* Be careful here about overflow */ if ((newlength = self->ob_size + n) <= 0 || - (newbytes = newlength * itemsize) / itemsize != newlength) + (newbytes = newlength * itemsize) / itemsize != + (size_t)newlength) goto nomem; PyMem_RESIZE(item, char, newbytes); if (item == NULL) { -- cgit v0.12