From f1c3eb41e31c483d9adf9adb4276a582ccb46b35 Mon Sep 17 00:00:00 2001 From: Derrick Brashear Date: Sun, 4 Mar 2012 09:48:07 -0500 Subject: [PATCH] macos: don't crash on krb5 damage if we get success but still no client, don't crash Reviewed-on: http://gerrit.openafs.org/6868 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 0a3f0608fcf6c14b44484cfa6fe106c568aa1035) Change-Id: I6c3147ab45552d9f393a05de21cc06d2dcabcf38 Reviewed-on: http://gerrit.openafs.org/6870 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- src/platform/DARWIN/AFSPreference/Krb5Util.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/platform/DARWIN/AFSPreference/Krb5Util.m b/src/platform/DARWIN/AFSPreference/Krb5Util.m index 6a54f2a5bd..fff03caad0 100644 --- a/src/platform/DARWIN/AFSPreference/Krb5Util.m +++ b/src/platform/DARWIN/AFSPreference/Krb5Util.m @@ -149,7 +149,7 @@ &me); in.client = me; } - if (ret == 0) { + if ((ret == 0) && (in.client)) { ret = krb5_build_principal_ext(kcontext, &server, krb5_princ_realm(kcontext, in.client)->length,