From 001e312ba5e7972b403e6b403b78bd53c22d8b80 Mon Sep 17 00:00:00 2001 From: "Roland C. Dowdeswell" Date: Thu, 21 Nov 2019 22:29:21 +0000 Subject: [PATCH] Make krb5_cc_close(ctx, NULL) stop SEGV'ing. --- lib/krb5/cache.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/krb5/cache.c b/lib/krb5/cache.c index 709049c21..1da78e534 100644 --- a/lib/krb5/cache.c +++ b/lib/krb5/cache.c @@ -782,6 +782,9 @@ krb5_cc_close(krb5_context context, { krb5_error_code ret; + if (!id) + return 0; + /* * We want to automatically acquire a PKIX credential using kx509. *