mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-03-09 10:14:11 +00:00
md: fix guards for mbedtls_md_error_from_psa()
This should be CRYPTO_CLIENT and not CRYPTO_C as this function can be used even when CRYPTO_C is not defined. Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
This commit is contained in:
parent
c50bf9549b
commit
b82fbf5634
@ -41,7 +41,7 @@
|
|||||||
#include "mbedtls/sha512.h"
|
#include "mbedtls/sha512.h"
|
||||||
#include "mbedtls/sha3.h"
|
#include "mbedtls/sha3.h"
|
||||||
|
|
||||||
#if defined(MBEDTLS_PSA_CRYPTO_C)
|
#if defined(MBEDTLS_PSA_CRYPTO_CLIENT)
|
||||||
#include <psa/crypto.h>
|
#include <psa/crypto.h>
|
||||||
#include "md_psa.h"
|
#include "md_psa.h"
|
||||||
#include "psa_util_internal.h"
|
#include "psa_util_internal.h"
|
||||||
@ -761,13 +761,13 @@ mbedtls_md_type_t mbedtls_md_get_type(const mbedtls_md_info_t *md_info)
|
|||||||
return md_info->type;
|
return md_info->type;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(MBEDTLS_PSA_CRYPTO_C)
|
#if defined(MBEDTLS_PSA_CRYPTO_CLIENT)
|
||||||
int mbedtls_md_error_from_psa(psa_status_t status)
|
int mbedtls_md_error_from_psa(psa_status_t status)
|
||||||
{
|
{
|
||||||
return PSA_TO_MBEDTLS_ERR_LIST(status, psa_to_md_errors,
|
return PSA_TO_MBEDTLS_ERR_LIST(status, psa_to_md_errors,
|
||||||
psa_generic_status_to_mbedtls);
|
psa_generic_status_to_mbedtls);
|
||||||
}
|
}
|
||||||
#endif /* MBEDTLS_PSA_CRYPTO_C */
|
#endif /* MBEDTLS_PSA_CRYPTO_CLIENT */
|
||||||
|
|
||||||
|
|
||||||
/************************************************************************
|
/************************************************************************
|
||||||
|
Loading…
x
Reference in New Issue
Block a user