summaryrefslogtreecommitdiff
path: root/usr/src/cmd/cmd-inet/common/kcmd.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src/cmd/cmd-inet/common/kcmd.c')
-rw-r--r--usr/src/cmd/cmd-inet/common/kcmd.c11
1 files changed, 9 insertions, 2 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