From 36399afd9d35da1ff066f4bcbb6fc01e6c0f34a4 Mon Sep 17 00:00:00 2001 From: Ezra Peisach Date: Tue, 30 Jan 2001 20:28:06 +0000 Subject: [PATCH] * sclient.c (main): Do not free auth_context unless set. (krb5-appl/895 from tim.mann@compaq.com) Pull up from 1-2 branch. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12973 dc483132-0cff-0310-8789-dd5450dbe970 --- src/appl/sample/sclient/ChangeLog | 7 ++++++- src/appl/sample/sclient/sclient.c | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/appl/sample/sclient/ChangeLog b/src/appl/sample/sclient/ChangeLog index d1d425de4..5a1209e8f 100644 --- a/src/appl/sample/sclient/ChangeLog +++ b/src/appl/sample/sclient/ChangeLog @@ -1,7 +1,12 @@ +2001-01-30 Ezra Peisach + + * sclient.c (main): Do not free auth_context unless + set. (krb5-appl/895 from tim.mann@compaq.com) + 2000-07-28 Ezra Peisach * sclient.c: Include unistd.h if present (for close prototype). - Change variable named sin (shadows maht library). + Change variable named sin (shadows math library). 2000-02-25 Ezra Peisach diff --git a/src/appl/sample/sclient/sclient.c b/src/appl/sample/sclient/sclient.c index 89fab6824..44a78735c 100644 --- a/src/appl/sample/sclient/sclient.c +++ b/src/appl/sample/sclient/sclient.c @@ -182,7 +182,7 @@ char *argv[]; krb5_free_principal(context, server); /* finished using it */ krb5_free_principal(context, client); krb5_cc_close(context, ccdef); - krb5_auth_con_free(context, auth_context); + if (auth_context) krb5_auth_con_free(context, auth_context); if (retval && retval != KRB5_SENDAUTH_REJECTED) { com_err(argv[0], retval, "while using sendauth"); -- 2.26.2