mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-06-12 08:21:54 +03:00
Explicit conversions and minor changes to prevent MSVC compiler warnings
This commit is contained in:
@ -42,8 +42,13 @@ void polarssl_strerror( int ret, char *buf, size_t buflen )
|
||||
size_t len;
|
||||
int use_ret;
|
||||
|
||||
if( buflen == 0 )
|
||||
return;
|
||||
|
||||
memset( buf, 0x00, buflen );
|
||||
|
||||
/* Reduce buflen to make sure MSVC _snprintf() ends with \0 as well */
|
||||
buflen -= 1;
|
||||
|
||||
if( ret < 0 )
|
||||
ret = -ret;
|
||||
|
||||
|
Reference in New Issue
Block a user