diff options
Diffstat (limited to 'contrib/bind9/lib/lwres/lwinetpton.c')
-rw-r--r-- | contrib/bind9/lib/lwres/lwinetpton.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/contrib/bind9/lib/lwres/lwinetpton.c b/contrib/bind9/lib/lwres/lwinetpton.c index 55c732c3d477..e0ea85df3573 100644 --- a/contrib/bind9/lib/lwres/lwinetpton.c +++ b/contrib/bind9/lib/lwres/lwinetpton.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1996-2001 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -19,7 +19,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static char rcsid[] = "$Id: lwinetpton.c,v 1.12 2007-06-19 23:47:22 tbox Exp $"; +static char rcsid[] = "$Id$"; #endif /* LIBC_SCCS and not lint */ #include <config.h> @@ -41,7 +41,7 @@ static char rcsid[] = "$Id: lwinetpton.c,v 1.12 2007-06-19 23:47:22 tbox Exp $"; static int inet_pton4(const char *src, unsigned char *dst); static int inet_pton6(const char *src, unsigned char *dst); -/*! +/*! * int * lwres_net_pton(af, src, dst) * convert from presentation format (which usually means ASCII printable) @@ -103,7 +103,12 @@ inet_pton4(const char *src, unsigned char *dst) { } else if (ch == '.' && saw_digit) { if (octets == 4) return (0); - *++tp = 0; + /* + * "clang --analyse" generates warnings using: + * *++tp = 0; + */ + tp++; + *tp = 0; saw_digit = 0; } else return (0); |