From 39dd640fdd04306dd52040ed74b4ee623ef21ee3 Mon Sep 17 00:00:00 2001 From: Barry Jaspan Date: Fri, 18 Oct 1996 21:31:17 +0000 Subject: [PATCH] * krsh.c, krlogin.c: don't print our own error message if kcmd returns -1 (it always printed something in that case, and error_message(-1) prints a mess [krb5-appl/70] git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@9211 dc483132-0cff-0310-8789-dd5450dbe970 --- src/appl/bsd/ChangeLog | 6 ++++++ src/appl/bsd/krlogin.c | 9 +++++---- src/appl/bsd/krsh.c | 9 +++++---- 3 files changed, 16 insertions(+), 8 deletions(-) diff --git a/src/appl/bsd/ChangeLog b/src/appl/bsd/ChangeLog index 44453312c..85ea415a0 100644 --- a/src/appl/bsd/ChangeLog +++ b/src/appl/bsd/ChangeLog @@ -1,3 +1,9 @@ +Fri Oct 18 17:26:51 1996 Barry Jaspan + + * krsh.c, krlogin.c: don't print our own error message if kcmd + returns -1 (it always printed something in that case, and + error_message(-1) prints a mess [krb5-appl/70] + Mon Sep 30 17:15:14 1996 Sam Hartman * login.c: Allow login -f to let you log in as root. diff --git a/src/appl/bsd/krlogin.c b/src/appl/bsd/krlogin.c index 5507ed329..2f0c34889 100644 --- a/src/appl/bsd/krlogin.c +++ b/src/appl/bsd/krlogin.c @@ -593,10 +593,11 @@ main(argc, argv) 0); /* Not any port # */ if (status) { /* should check for KDC_PR_UNKNOWN, NO_TKT_FILE here -- XXX */ - fprintf(stderr, - "%s: kcmd to host %s failed - %s\n",orig_argv[0], host, - error_message(status)); - try_normal(orig_argv); + if (status != -1) + fprintf(stderr, + "%s: kcmd to host %s failed - %s\n",orig_argv[0], host, + error_message(status)); + try_normal(orig_argv); } rem = sock; diff --git a/src/appl/bsd/krsh.c b/src/appl/bsd/krsh.c index 6bf8f9d37..a1cca9c60 100644 --- a/src/appl/bsd/krsh.c +++ b/src/appl/bsd/krsh.c @@ -357,10 +357,11 @@ main(argc, argv0) 1); /* Always set anyport, there is no need not to. --proven */ if (status) { /* check NO_TKT_FILE or equivalent... */ - fprintf(stderr, - "%s: kcmd to host %s failed - %s\n",argv0[0], host, - error_message(status)); - try_normal(argv0); + if (status != -1) + fprintf(stderr, + "%s: kcmd to host %s failed - %s\n",argv0[0], host, + error_message(status)); + try_normal(argv0); } /* Setup for des_read and write */ -- 2.26.2