]> granicus.if.org Git - python/commitdiff
Jim Ahlstrom patch: BIGCHUNK is too large for 16-bit int.
authorGuido van Rossum <guido@python.org>
Thu, 14 Jan 1999 19:00:14 +0000 (19:00 +0000)
committerGuido van Rossum <guido@python.org>
Thu, 14 Jan 1999 19:00:14 +0000 (19:00 +0000)
Objects/fileobject.c

index ed15587ef65c927eada402a853c055ac52d2185f..6d57aeacc3daa5e29f180e8617115a5c63bc8a58 100644 (file)
@@ -452,7 +452,11 @@ file_isatty(f, args)
 #define SMALLCHUNK BUFSIZ
 #endif
 
-#define BIGCHUNK (512*1024)
+#if SIZEOF_INT < 4
+#define BIGCHUNK  (512 * 32)
+#else
+#define BIGCHUNK  (512 * 1024)
+#endif
 
 static size_t
 new_buffersize(f, currentsize)