diff options
Diffstat (limited to 'usr/src/cmd/cmd-inet')
| -rw-r--r-- | usr/src/cmd/cmd-inet/common/kcmd.c | 11 | ||||
| -rw-r--r-- | usr/src/cmd/cmd-inet/usr.bin/dns-sd/Makefile | 2 | ||||
| -rw-r--r-- | usr/src/cmd/cmd-inet/usr.bin/finger.c | 6 | ||||
| -rw-r--r-- | usr/src/cmd/cmd-inet/usr.bin/pppd/plugins/passprompt.c | 7 | ||||
| -rw-r--r-- | usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile | 4 | ||||
| -rw-r--r-- | usr/src/cmd/cmd-inet/usr.sbin/ipadm/ipadm.c | 5 | ||||
| -rw-r--r-- | usr/src/cmd/cmd-inet/usr.sbin/ping/ping.c | 4 | ||||
| -rw-r--r-- | usr/src/cmd/cmd-inet/usr.sbin/wificonfig/wificonfig.c | 9 |
8 files changed, 33 insertions, 15 deletions
diff --git a/usr/src/cmd/cmd-inet/common/kcmd.c b/usr/src/cmd/cmd-inet/common/kcmd.c index 35d2c4ee96..c4a078c96a 100644 --- a/usr/src/cmd/cmd-inet/common/kcmd.c +++ b/usr/src/cmd/cmd-inet/common/kcmd.c @@ -20,6 +20,10 @@ * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ +/* + * Copyright (c) 2018, Joyent, Inc. + */ + /* derived from @(#)rcmd.c 5.17 (Berkeley) 6/27/88 */ #include <unistd.h> @@ -412,8 +416,11 @@ kcmd(int *sock, char **ahost, ushort_t rport, *sock = s; /* pass back credentials if wanted */ - if (cred) (void) krb5_copy_creds(bsd_context, ret_cred, cred); - krb5_free_creds(bsd_context, ret_cred); + if (cred) + (void) krb5_copy_creds(bsd_context, ret_cred, cred); + + krb5_free_creds(bsd_context, ret_cred); + /* * Initialize *authconp to auth_context, so * that the clients can make use of it diff --git a/usr/src/cmd/cmd-inet/usr.bin/dns-sd/Makefile b/usr/src/cmd/cmd-inet/usr.bin/dns-sd/Makefile index c58b1a375f..9bc700ab29 100644 --- a/usr/src/cmd/cmd-inet/usr.bin/dns-sd/Makefile +++ b/usr/src/cmd/cmd-inet/usr.bin/dns-sd/Makefile @@ -25,7 +25,7 @@ SRCS= ClientCommon.c dns-sd.c SRCDIR= $(SRC)/contrib/mDNSResponder CFLAGS += $(CSTD_GNU99) CPPFLAGS += -I$(SRCDIR)/mDNSShared -CPPFLAGS += -DMDNS_VERSIONSTR_NODTS +CPPFLAGS += -DmDNSResponderVersion=878.1.1 LDLIBS += -lsocket -ldns_sd # not linted diff --git a/usr/src/cmd/cmd-inet/usr.bin/finger.c b/usr/src/cmd/cmd-inet/usr.bin/finger.c index cdc94a7be6..d42d90eacf 100644 --- a/usr/src/cmd/cmd-inet/usr.bin/finger.c +++ b/usr/src/cmd/cmd-inet/usr.bin/finger.c @@ -38,6 +38,10 @@ */ /* + * Copyright (c) 2018, Joyent, Inc. + */ + +/* * This is a finger program. It prints out useful information about users * by digging it up from various system files. * @@ -1359,7 +1363,7 @@ AlreadyPrinted(uid_t uid) while (i++ < PPIndex) { if (PlanPrinted[i] == uid) - return (1); + return (1); } if (i < PPMAX) { PlanPrinted[i] = uid; diff --git a/usr/src/cmd/cmd-inet/usr.bin/pppd/plugins/passprompt.c b/usr/src/cmd/cmd-inet/usr.bin/pppd/plugins/passprompt.c index ce361e9c37..a96fa32ba8 100644 --- a/usr/src/cmd/cmd-inet/usr.bin/pppd/plugins/passprompt.c +++ b/usr/src/cmd/cmd-inet/usr.bin/pppd/plugins/passprompt.c @@ -8,6 +8,11 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ + +/* + * Copyright (c) 2018, Joyent, Inc. + */ + #include <errno.h> #include <unistd.h> #include <fcntl.h> @@ -70,7 +75,7 @@ static int promptpass(char *user, char *passwd) argv[0] = promptprog; argv[1] = user == NULL ? "" : user; argv[2] = remote_name; - slprintf(fdstr, sizeof (fdstr), "%d", p[1]); + (void) slprintf(fdstr, sizeof (fdstr), "%d", p[1]); argv[3] = fdstr; argv[4] = NULL; (void) execv(*argv, argv); diff --git a/usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile b/usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile index 7f3365c9ea..afac8667f2 100644 --- a/usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile +++ b/usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile @@ -40,7 +40,7 @@ MDNSFLAGS= -DNOT_HAVE_SA_LEN \ -D_XPG4_2 -D__EXTENSIONS__ -DHAVE_BROKEN_RECVIF_NAME \ -DHAVE_IPV6=1 -Dasm=__asm -DMDNSD_NOROOT \ -DPID_FILE=\"\" -DMDNSD_USER=\"noaccess\" \ - -DMDNS_VERSIONSTR_NODTS + -DmDNSResponderVersion=878.1.1 include ../../../Makefile.cmd @@ -66,7 +66,7 @@ $(PROG): $(OBJS) include ../Makefile.lib -CSTD = $(CSTD_GNU99) +CSTD= $(CSTD_GNU99) CPPFLAGS += -D_REENTRANT $(MDNSFLAGS) CPPFLAGS += -I$(SRCDIR)/mDNSShared -I$(SRCDIR)/mDNSPosix CPPFLAGS += -I$(SRCDIR)/mDNSCore diff --git a/usr/src/cmd/cmd-inet/usr.sbin/ipadm/ipadm.c b/usr/src/cmd/cmd-inet/usr.sbin/ipadm/ipadm.c index 4dbbb83590..30e2f0f549 100644 --- a/usr/src/cmd/cmd-inet/usr.sbin/ipadm/ipadm.c +++ b/usr/src/cmd/cmd-inet/usr.sbin/ipadm/ipadm.c @@ -22,7 +22,7 @@ /* * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. * Copyright 2017 Nexenta Systems, Inc. - * Copyright 2017 Joyent, Inc. + * Copyright (c) 2018, Joyent, Inc. * Copyright 2017 Gary Mills * Copyright (c) 2016, Chris Fraire <cfraire@me.com>. */ @@ -1636,8 +1636,7 @@ is_from_gz(const char *lifname) if (if_info->ifi_cflags & IFIF_L3PROTECT) ret = _B_TRUE; - if (if_info) - ipadm_free_if_info(if_info); + ipadm_free_if_info(if_info); return (ret); } diff --git a/usr/src/cmd/cmd-inet/usr.sbin/ping/ping.c b/usr/src/cmd/cmd-inet/usr.sbin/ping/ping.c index c6f8257ae9..9f959976a8 100644 --- a/usr/src/cmd/cmd-inet/usr.sbin/ping/ping.c +++ b/usr/src/cmd/cmd-inet/usr.sbin/ping/ping.c @@ -38,7 +38,7 @@ */ /* - * Copyright (c) 2017, Joyent, Inc. + * Copyright (c) 2018, Joyent, Inc. */ #include <assert.h> @@ -1989,7 +1989,7 @@ recv_icmp_packet(struct addrinfo *ai_dst, int recv_sock6, int recv_sock, progname, strerror(errno)); } continue; - } if (cc > 0) { + } else if (cc > 0) { check_reply(ai_dst, &in_msg, cc, udp_src_port); } diff --git a/usr/src/cmd/cmd-inet/usr.sbin/wificonfig/wificonfig.c b/usr/src/cmd/cmd-inet/usr.sbin/wificonfig/wificonfig.c index ad5100c1b0..5a9dc9889b 100644 --- a/usr/src/cmd/cmd-inet/usr.sbin/wificonfig/wificonfig.c +++ b/usr/src/cmd/cmd-inet/usr.sbin/wificonfig/wificonfig.c @@ -23,7 +23,9 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" +/* + * Copyright (c) 2018, Joyent, Inc. + */ #include <stdio.h> #include <stdlib.h> @@ -2531,7 +2533,7 @@ do_deletepf(int fd, int argc, char **argv) B_FALSE); free(section_id); p_section = p_sectionbak; - continue; + continue; } p_section = p_section->section_next; } @@ -2751,8 +2753,9 @@ do_rmprefer(int fd, int argc, char **argv) return (B_FALSE); pae = plist->ael_head; while (pae != NULL) { + ae_t *next = pae->ae_next; free(pae); - pae = pae->ae_next; + pae = next; } plist->ael_head = plist->ael_tail = NULL; plist->ael_argc = 0; |
