]> sjero.net Git - wget/commitdiff
Do not define max twice.
authorGiuseppe Scrivano <gscrivano@gnu.org>
Sat, 13 Aug 2011 08:44:40 +0000 (10:44 +0200)
committerGiuseppe Scrivano <gscrivano@gnu.org>
Sat, 13 Aug 2011 08:44:40 +0000 (10:44 +0200)
src/ChangeLog
src/retr.c

index c45ff1805dc77ded46c6032a871ee80b15a5ee12..f4ac255940b6587887933fbe8fd4dbad004e4666 100644 (file)
@@ -1,5 +1,7 @@
 2011-08-13  Giuseppe Scrivano  <gscrivano@gnu.org>
 
 2011-08-13  Giuseppe Scrivano  <gscrivano@gnu.org>
 
+       * retr.c (fd_read_body): Ensure max is not already defined.
+
        * mswindows.h (snprintf): Remove definition.
        (vsnprintf): Likewise.
 
        * mswindows.h (snprintf): Remove definition.
        (vsnprintf): Likewise.
 
index 54937d862bc3dcb0f0d064ac06dc19b017944198..73947658c2d73b10b975ce589d39d1a2c2bb7401 100644 (file)
@@ -207,6 +207,7 @@ fd_read_body (int fd, FILE *out, wgint toread, wgint startpos,
               wgint *qtyread, wgint *qtywritten, double *elapsed, int flags)
 {
   int ret = 0;
               wgint *qtyread, wgint *qtywritten, double *elapsed, int flags)
 {
   int ret = 0;
+#undef max
 #define max(a,b) ((a) > (b) ? (a) : (b))
   int dlbufsize = max (BUFSIZ, 8 * 1024);
   char *dlbuf = xmalloc (dlbufsize);
 #define max(a,b) ((a) > (b) ? (a) : (b))
   int dlbufsize = max (BUFSIZ, 8 * 1024);
   char *dlbuf = xmalloc (dlbufsize);