1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-08-08 17:42:09 +03:00

cleanup library and some basic tests. Includes, add guards to includes

This commit is contained in:
Rich Evans
2015-02-06 13:43:58 +00:00
parent e83ac1d7d1
commit 00ab47026b
100 changed files with 284 additions and 192 deletions

View File

@@ -65,12 +65,12 @@ print TEST_FILE << "END";
#include POLARSSL_CONFIG_FILE
#endif
$test_helpers
$suite_pre_code
$suite_header
$suite_post_code
$test_helpers
END
$test_main =~ s/SUITE_PRE_DEP/$suite_pre_code/;

View File

@@ -1,6 +1,9 @@
#if defined(POLARSSL_PLATFORM_C)
#include "polarssl/platform.h"
#else
#include <stdio.h>
#define polarssl_printf printf
#define polarssl_fprintf fprintf
#define polarssl_malloc malloc
#define polarssl_free free
#endif

View File

@@ -1,15 +1,3 @@
#include <stdio.h>
#include <string.h>
#if defined(POLARSSL_PLATFORM_C)
#include "polarssl/platform.h"
#else
#define polarssl_printf printf
#define polarssl_fprintf fprintf
#define polarssl_malloc malloc
#define polarssl_free free
#endif
#if defined(POLARSSL_MEMORY_BUFFER_ALLOC_C)
#include "polarssl/memory_buffer_alloc.h"
#endif

View File

@@ -1,6 +1,8 @@
/* BEGIN_HEADER */
#include <polarssl/ctr_drbg.h>
#include <string.h>
int test_offset_idx;
int entropy_func( void *data, unsigned char *buf, size_t len )
{

View File

@@ -1,6 +1,8 @@
/* BEGIN_HEADER */
#include <polarssl/hmac_drbg.h>
#include <string.h>
typedef struct
{
unsigned char *p;