diff options
author | Bruce Momjian <bruce@momjian.us> | 2003-06-24 22:42:42 +0000 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 2003-06-24 22:42:42 +0000 |
commit | 4b1fe23153430618359b635f3550265d394bc20a (patch) | |
tree | fdeda46f5d16dc886bf92ccefeb08ec5fcaf0d34 /src | |
parent | 945543d919ced497e3fc8165b11142ddc014b9cb (diff) | |
download | postgresql-4b1fe23153430618359b635f3550265d394bc20a.tar.gz postgresql-4b1fe23153430618359b635f3550265d394bc20a.zip |
Prevent compiler warning from sprintf in recent ipv6 patch.
Diffstat (limited to 'src')
-rw-r--r-- | src/backend/utils/adt/inet_net_ntop.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/utils/adt/inet_net_ntop.c b/src/backend/utils/adt/inet_net_ntop.c index a355e402cb2..bbf498e239b 100644 --- a/src/backend/utils/adt/inet_net_ntop.c +++ b/src/backend/utils/adt/inet_net_ntop.c @@ -16,7 +16,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static const char rcsid[] = "$Id: inet_net_ntop.c,v 1.13 2003/06/24 22:21:22 momjian Exp $"; +static const char rcsid[] = "$Id: inet_net_ntop.c,v 1.14 2003/06/24 22:42:42 momjian Exp $"; #endif #include "postgres.h" @@ -270,9 +270,9 @@ inet_cidr_ntop_ipv6(const u_char *src, int bits, char *dst, size_t size) if (!double_colon) { if (bits < 128 - 32) - cp += SPRINTF((cp, "::", bits)); + cp += SPRINTF((cp, "::%d", bits)); else if (bits < 128 - 16) - cp += SPRINTF((cp, ":0", bits)); + cp += SPRINTF((cp, ":0%d", bits)); } /* Format CIDR /width. */ |