]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
[MINOR] fix a few remaining printf-like formats on 64-bit platforms
authorWilly Tarreau <w@1wt.eu>
Sat, 11 Apr 2009 17:42:49 +0000 (19:42 +0200)
committerWilly Tarreau <w@1wt.eu>
Sat, 11 Apr 2009 17:42:49 +0000 (19:42 +0200)
Mainly two sizeof() returning size_t which is not the size of an int
on 64-bit platforms.

src/cfgparse.c
src/standard.c

index 46cc1a66fab4c7fb3480b46a79d1e7ad683a8dcf..83e8af6ebe18f26236a5fbc7ba14cf09634b37b4 100644 (file)
@@ -3091,7 +3091,7 @@ int readcfgfile(const char *file)
                         * Watch out for the last line without the terminating '\n'!
                         */
                        Alert("parsing [%s:%d]: line too long, limit: %d.\n",
-                               file, linenum, sizeof(thisline)-1);
+                             file, linenum, (int)sizeof(thisline)-1);
                        goto err;
                }
 
index 246561977bff630b40e6bcc8d9ef790494674fc7..906f2a730f5ccd0457324eae7a9c587e8436d09b 100644 (file)
@@ -128,7 +128,7 @@ struct sockaddr_un *str2sun(const char *str)
        strsz = strlen(str) + 1;
        if (strsz > sizeof(su.sun_path)) {
                Alert("Socket path '%s' too long (max %d)\n",
-                       str, sizeof(su.sun_path) - 1);
+                     str, (int)sizeof(su.sun_path) - 1);
        } else {
                su.sun_family = AF_UNIX;
                memcpy(su.sun_path, str, strsz);