mbedtls/library/version.c
Harry Ramsey e8e23fb519 Include ssl_misc.h for additional SSL helper files
This commit replaces #include "common.h" in favour of #include
"ssl_misc.h".

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2024-10-11 12:21:30 +01:00

33 lines
648 B
C

/*
* Version information
*
* Copyright The Mbed TLS Contributors
* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
*/
#include "ssl_misc.h"
#if defined(MBEDTLS_VERSION_C)
#include "mbedtls/version.h"
#include <string.h>
unsigned int mbedtls_version_get_number(void)
{
return MBEDTLS_VERSION_NUMBER;
}
void mbedtls_version_get_string(char *string)
{
memcpy(string, MBEDTLS_VERSION_STRING,
sizeof(MBEDTLS_VERSION_STRING));
}
void mbedtls_version_get_string_full(char *string)
{
memcpy(string, MBEDTLS_VERSION_STRING_FULL,
sizeof(MBEDTLS_VERSION_STRING_FULL));
}
#endif /* MBEDTLS_VERSION_C */