free memories that are bound to the context
This commit is contained in:
committed by
Andreas Steffen
parent
cb83fb3b72
commit
8209ab86a5
@@ -733,8 +733,8 @@ METHOD(pts_t, read_pcr, bool,
|
|||||||
*output = chunk_clone(*output);
|
*output = chunk_clone(*output);
|
||||||
|
|
||||||
chunk_clear(&pcr_value);
|
chunk_clear(&pcr_value);
|
||||||
Tspi_Context_Close(hContext);
|
|
||||||
DBG3(DBG_PTS, "PCR %d value:%B", pcr_num, output);
|
DBG3(DBG_PTS, "PCR %d value:%B", pcr_num, output);
|
||||||
|
Tspi_Context_Close(hContext);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
err:
|
err:
|
||||||
@@ -1330,11 +1330,14 @@ static bool has_tpm(private_pts_t *this)
|
|||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
this->tpm_version_info = chunk_clone(this->tpm_version_info);
|
this->tpm_version_info = chunk_clone(this->tpm_version_info);
|
||||||
|
|
||||||
|
Tspi_Context_FreeMemory(hContext, NULL);
|
||||||
Tspi_Context_Close(hContext);
|
Tspi_Context_Close(hContext);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
err:
|
err:
|
||||||
DBG1(DBG_PTS, "TPM not available: tss error 0x%x", result);
|
DBG1(DBG_PTS, "TPM not available: tss error 0x%x", result);
|
||||||
|
Tspi_Context_FreeMemory(hContext, NULL);
|
||||||
Tspi_Context_Close(hContext);
|
Tspi_Context_Close(hContext);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user