diff --git a/src/tss2-fapi/fapi_util.c b/src/tss2-fapi/fapi_util.c index f67d398c3..6a64ac347 100644 --- a/src/tss2-fapi/fapi_util.c +++ b/src/tss2-fapi/fapi_util.c @@ -1204,7 +1204,7 @@ ifapi_session_clean(FAPI_CONTEXT *context) if (context->policy_session && context->policy_session != ESYS_TR_NONE) { Esys_FlushContext(context->esys, context->policy_session); } - if (context->session1 != ESYS_TR_NONE) { + if (context->session1 != ESYS_TR_NONE && context->session1 != ESYS_TR_PASSWORD) { if (context->session1 == context->session2) { context->session2 = ESYS_TR_NONE; }