mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-12-24 17:41:01 +03:00
- mpi_init() and mpi_free() only accept a single argument and do not accept variable arguments anymore. This prevents unexpected memory corruption in a number of use cases.
This commit is contained in:
@@ -45,7 +45,7 @@ debug_print_mpi:radix:value:file:line:prefix:result_str
|
||||
struct buffer_data buffer;
|
||||
mpi val;
|
||||
|
||||
mpi_init( &val, NULL );
|
||||
mpi_init( &val );
|
||||
|
||||
memset( &ssl, 0, sizeof( ssl_context ) );
|
||||
memset( buffer.buf, 0, 2000 );
|
||||
@@ -57,6 +57,8 @@ debug_print_mpi:radix:value:file:line:prefix:result_str
|
||||
debug_print_mpi( &ssl, 0, {file}, {line}, {prefix}, &val);
|
||||
|
||||
TEST_ASSERT( strcmp( buffer.buf, {result_str} ) == 0 );
|
||||
|
||||
mpi_free( &val );
|
||||
}
|
||||
END_CASE
|
||||
|
||||
|
||||
Reference in New Issue
Block a user