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

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