X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/7b3d425783f68e3784ac25af60ed9407a2ae9a18..50abd20bb3dc3d853de22cd5cf8198edfde5ae92:/lib/compat.c diff --git a/lib/compat.c b/lib/compat.c index f47275f5..922d1199 100644 --- a/lib/compat.c +++ b/lib/compat.c @@ -83,10 +83,10 @@ char *rep_inet_ntoa(struct in_addr ip) unsigned char *p = (unsigned char *)&ip.s_addr; static char buf[18]; #if WORDS_BIGENDIAN - slprintf(buf, 17, "%d.%d.%d.%d", + slprintf(buf, 18, "%d.%d.%d.%d", (int)p[0], (int)p[1], (int)p[2], (int)p[3]); #else - slprintf(buf, 17, "%d.%d.%d.%d", + slprintf(buf, 18, "%d.%d.%d.%d", (int)p[3], (int)p[2], (int)p[1], (int)p[0]); #endif return buf;