* login.c (main): Only destroy xtra_creds if non-null. (Patch from Richard Basch.)
authorKen Raeburn <raeburn@mit.edu>
Thu, 10 Feb 2000 09:31:45 +0000 (09:31 +0000)
committerKen Raeburn <raeburn@mit.edu>
Thu, 10 Feb 2000 09:31:45 +0000 (09:31 +0000)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12031 dc483132-0cff-0310-8789-dd5450dbe970

src/appl/bsd/ChangeLog
src/appl/bsd/login.c

index e5b56a40a8ba133bbb48fe9d2e857ba01b6505d4..31bd1b4a0aca40eea7676f4765c8ed20fae8b79e 100644 (file)
@@ -1,3 +1,8 @@
+2000-02-10  Ken Raeburn  <raeburn@mit.edu>
+
+       * login.c (main): Only destroy xtra_creds if non-null.  (Patch
+       from Richard Basch.)
+
 2000-02-04  Tom Yu  <tlyu@mit.edu>
 
        * login.c (main): Reorder some control flow to avoid security hole
index 237cb4a7de44d0124287cde601d74bc32837cbb1..1832aafb2d5a29bcf054194b1d8c4edb24aacd8a 100644 (file)
@@ -1643,7 +1643,8 @@ int main(argc, argv)
            com_err(argv[0], retval, "while storing credentials");
        }
 
-       krb5_cc_destroy(kcontext, xtra_creds);
+       if (xtra_creds)
+           krb5_cc_destroy(kcontext, xtra_creds);
     } else if (forwarded_v5_tickets && rewrite_ccache) {
        if ((retval = krb5_cc_initialize (kcontext, ccache, me))) {
            syslog(LOG_ERR,