Skip to content

Commit 5697dfd

Browse files
Always initialize out cred in gp_import_gssx_cred()
Signed-off-by: Robbie Harwood <[email protected]> Reviewed-by: Simo Sorce <[email protected]> Merges: #244
1 parent f91e23f commit 5697dfd

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/gp_export.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -449,6 +449,8 @@ uint32_t gp_import_gssx_cred(uint32_t *min, struct gp_call_ctx *gpcall,
449449
uint32_t ret_min = 0;
450450
int ret;
451451

452+
*out = GSS_C_NO_CREDENTIAL;
453+
452454
handle = gp_service_get_creds_handle(gpcall->service);
453455
if (!handle) {
454456
ret_maj = GSS_S_FAILURE;
@@ -470,7 +472,6 @@ uint32_t gp_import_gssx_cred(uint32_t *min, struct gp_call_ctx *gpcall,
470472
if (ret) {
471473
/* Allow for re-issuance of the keytab. */
472474
GPDEBUG("Stored ccache failed to decrypt; treating as empty\n");
473-
*out = GSS_C_NO_CREDENTIAL;
474475
goto done;
475476
}
476477

0 commit comments

Comments
 (0)