diff options
author | 1998-03-19 00:29:51 +0000 | |
---|---|---|
committer | 1998-03-19 00:29:51 +0000 | |
commit | dfa5a4f6e3a2e75d92d79ce0e572feb85230a557 (patch) | |
tree | edbbc806584b9a4898b296c427abdb5c7f559aea /lib/libc/net | |
parent | Some -Wall (diff) | |
download | wireguard-openbsd-dfa5a4f6e3a2e75d92d79ce0e572feb85230a557.tar.xz wireguard-openbsd-dfa5a4f6e3a2e75d92d79ce0e572feb85230a557.zip |
some -Wall
Diffstat (limited to 'lib/libc/net')
-rw-r--r-- | lib/libc/net/rcmd.c | 5 | ||||
-rw-r--r-- | lib/libc/net/res_debug.c | 7 | ||||
-rw-r--r-- | lib/libc/net/res_send.c | 8 |
3 files changed, 10 insertions, 10 deletions
diff --git a/lib/libc/net/rcmd.c b/lib/libc/net/rcmd.c index ad701acf0e9..c933f5b4475 100644 --- a/lib/libc/net/rcmd.c +++ b/lib/libc/net/rcmd.c @@ -34,7 +34,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static char *rcsid = "$OpenBSD: rcmd.c,v 1.30 1998/02/12 02:21:19 deraadt Exp $"; +static char *rcsid = "$OpenBSD: rcmd.c,v 1.31 1998/03/19 00:30:05 millert Exp $"; #endif /* LIBC_SCCS and not lint */ #include <sys/param.h> @@ -402,7 +402,6 @@ __ivaliduser(hostf, raddrl, luser, ruser) const char *luser, *ruser; { register char *user, *p; - int ch; char *buf; const char *auser, *ahost; int hostok, userok; @@ -427,7 +426,7 @@ __ivaliduser(hostf, raddrl, luser, ruser) continue; if (*p == ' ' || *p == '\t') { *p++ = '\0'; - while (*p == ' ' || *p == '\t' && p < buf + buflen) + while ((*p == ' ' || *p == '\t') && p < buf + buflen) p++; if (p >= buf + buflen) continue; diff --git a/lib/libc/net/res_debug.c b/lib/libc/net/res_debug.c index 908ad421b7b..c2725395a04 100644 --- a/lib/libc/net/res_debug.c +++ b/lib/libc/net/res_debug.c @@ -1,4 +1,4 @@ -/* $OpenBSD: res_debug.c,v 1.8 1997/07/09 01:08:51 millert Exp $ */ +/* $OpenBSD: res_debug.c,v 1.9 1998/03/19 00:30:06 millert Exp $ */ /* * ++Copyright++ 1985, 1990, 1993 @@ -82,7 +82,7 @@ static char sccsid[] = "@(#)res_debug.c 8.1 (Berkeley) 6/4/93"; static char rcsid[] = "$From: res_debug.c,v 8.19 1996/11/26 10:11:23 vixie Exp $"; #else -static char rcsid[] = "$OpenBSD: res_debug.c,v 1.8 1997/07/09 01:08:51 millert Exp $"; +static char rcsid[] = "$OpenBSD: res_debug.c,v 1.9 1998/03/19 00:30:06 millert Exp $"; #endif #endif /* LIBC_SCCS and not lint */ @@ -437,11 +437,12 @@ __p_fqnname(cp, msg, msglen, name, namelen) if ((n = dn_expand(msg, cp + msglen, cp, name, namelen)) < 0) return (NULL); newlen = strlen (name); - if (newlen == 0 || name[newlen - 1] != '.') + if (newlen == 0 || name[newlen - 1] != '.') { if (newlen+1 >= namelen) /* Lack space for final dot */ return (NULL); else strcpy(name + newlen, "."); + } return (cp + n); } diff --git a/lib/libc/net/res_send.c b/lib/libc/net/res_send.c index b89398aab3f..0cda3510ebe 100644 --- a/lib/libc/net/res_send.c +++ b/lib/libc/net/res_send.c @@ -1,4 +1,4 @@ -/* $OpenBSD: res_send.c,v 1.7 1997/06/04 03:18:41 dm Exp $ */ +/* $OpenBSD: res_send.c,v 1.8 1998/03/19 00:30:08 millert Exp $ */ /* * ++Copyright++ 1985, 1989, 1993 @@ -60,7 +60,7 @@ static char sccsid[] = "@(#)res_send.c 8.1 (Berkeley) 6/4/93"; static char rcsid[] = "$From: res_send.c,v 8.12 1996/10/08 04:51:06 vixie Exp $"; #else -static char rcsid[] = "$OpenBSD: res_send.c,v 1.7 1997/06/04 03:18:41 dm Exp $"; +static char rcsid[] = "$OpenBSD: res_send.c,v 1.8 1998/03/19 00:30:08 millert Exp $"; #endif #endif /* LIBC_SCCS and not lint */ @@ -751,12 +751,12 @@ read_len: } /*foreach ns*/ } /*foreach retry*/ res_close(); - if (!v_circuit) + if (!v_circuit) { if (!gotsomewhere) errno = ECONNREFUSED; /* no nameservers found */ else errno = ETIMEDOUT; /* no answer obtained */ - else + } else errno = terrno; return (-1); } |