mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-08-08 17:42:09 +03:00
Allow building with the -Wunused flag
Make some functions non-static, to avoid Wunused function warnings. Make a function scoped variable block scoped instead, to avoid Wunused variable warnings in some configurations.
This commit is contained in:
@@ -48,7 +48,7 @@ static int entropy_dummy_source( void *data, unsigned char *output,
|
||||
* This might break memory checks in the future if sources need 'free-ing' then
|
||||
* as well.
|
||||
*/
|
||||
static void entropy_clear_sources( mbedtls_entropy_context *ctx )
|
||||
void entropy_clear_sources( mbedtls_entropy_context *ctx )
|
||||
{
|
||||
ctx->source_count = 0;
|
||||
}
|
||||
@@ -58,7 +58,7 @@ static void entropy_clear_sources( mbedtls_entropy_context *ctx )
|
||||
*/
|
||||
static unsigned char buffer_seed[MBEDTLS_ENTROPY_BLOCK_SIZE];
|
||||
|
||||
static int buffer_nv_seed_read( unsigned char *buf, size_t buf_len )
|
||||
int buffer_nv_seed_read( unsigned char *buf, size_t buf_len )
|
||||
{
|
||||
if( buf_len != MBEDTLS_ENTROPY_BLOCK_SIZE )
|
||||
return( -1 );
|
||||
@@ -67,7 +67,7 @@ static int buffer_nv_seed_read( unsigned char *buf, size_t buf_len )
|
||||
return( 0 );
|
||||
}
|
||||
|
||||
static int buffer_nv_seed_write( unsigned char *buf, size_t buf_len )
|
||||
int buffer_nv_seed_write( unsigned char *buf, size_t buf_len )
|
||||
{
|
||||
if( buf_len != MBEDTLS_ENTROPY_BLOCK_SIZE )
|
||||
return( -1 );
|
||||
@@ -98,7 +98,7 @@ static int write_nv_seed( unsigned char *buf, size_t buf_len )
|
||||
return( 0 );
|
||||
}
|
||||
|
||||
static int read_nv_seed( unsigned char *buf, size_t buf_len )
|
||||
int read_nv_seed( unsigned char *buf, size_t buf_len )
|
||||
{
|
||||
FILE *f;
|
||||
|
||||
|
Reference in New Issue
Block a user