Blame SOURCES/Always-initialize-out-cred-in-gp_import_gssx_cred.patch

cc8bf3
From ad753abb87a561ae72db09f210390343d0084431 Mon Sep 17 00:00:00 2001
cc8bf3
From: Robbie Harwood <rharwood@redhat.com>
cc8bf3
Date: Mon, 15 Apr 2019 19:54:17 -0400
cc8bf3
Subject: [PATCH] Always initialize out cred in gp_import_gssx_cred()
cc8bf3
cc8bf3
Signed-off-by: Robbie Harwood <rharwood@redhat.com>
cc8bf3
Reviewed-by: Simo Sorce <simo@redhat.com>
cc8bf3
Merges: #244
cc8bf3
(cherry picked from commit 5697dfd94345c945f93070c40b9d4480f3d3d7ea)
cc8bf3
---
cc8bf3
 proxy/src/gp_export.c | 3 ++-
cc8bf3
 1 file changed, 2 insertions(+), 1 deletion(-)
cc8bf3
cc8bf3
diff --git a/proxy/src/gp_export.c b/proxy/src/gp_export.c
cc8bf3
index 5e8e160..403e339 100644
cc8bf3
--- a/proxy/src/gp_export.c
cc8bf3
+++ b/proxy/src/gp_export.c
cc8bf3
@@ -449,6 +449,8 @@ uint32_t gp_import_gssx_cred(uint32_t *min, struct gp_call_ctx *gpcall,
cc8bf3
     uint32_t ret_min = 0;
cc8bf3
     int ret;
cc8bf3
 
cc8bf3
+    *out = GSS_C_NO_CREDENTIAL;
cc8bf3
+
cc8bf3
     handle = gp_service_get_creds_handle(gpcall->service);
cc8bf3
     if (!handle) {
cc8bf3
         ret_maj = GSS_S_FAILURE;
cc8bf3
@@ -470,7 +472,6 @@ uint32_t gp_import_gssx_cred(uint32_t *min, struct gp_call_ctx *gpcall,
cc8bf3
     if (ret) {
cc8bf3
         /* Allow for re-issuance of the keytab. */
cc8bf3
         GPDEBUG("Stored ccache failed to decrypt; treating as empty\n");
cc8bf3
-        *out = GSS_C_NO_CREDENTIAL;
cc8bf3
         goto done;
cc8bf3
     }
cc8bf3