1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-28 00:21:48 +03:00

Adapt programs to the new debug API

This commit is contained in:
Manuel Pégourié-Gonnard
2015-06-23 17:35:03 +02:00
parent fd474233c8
commit 61ee351af4
10 changed files with 56 additions and 36 deletions

View File

@ -390,11 +390,13 @@ struct options
int badmac_limit; /* Limit of records with bad MAC */
} opt;
static void my_debug( void *ctx, int level, const char *str )
static void my_debug( void *ctx, int level,
const char *file, int line,
const char *str )
{
((void) level);
mbedtls_fprintf( (FILE *) ctx, "%s", str );
mbedtls_fprintf( (FILE *) ctx, "%s:%04d: %s", file, line, str );
fflush( (FILE *) ctx );
}