mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-28 00:21:48 +03:00
Fix code styling for return statements
This commit is contained in:
@ -624,24 +624,24 @@ static int compat_snprintf(char *str, size_t size, const char *format, ...)
|
||||
if ( res < 0 )
|
||||
return( (int) size + 20 );
|
||||
|
||||
return res;
|
||||
return( res );
|
||||
}
|
||||
|
||||
#define snprintf compat_snprintf
|
||||
#endif /* _MSC_VER && !snprintf && !EFIX64 && !EFI32 */
|
||||
|
||||
#define SAFE_SNPRINTF() \
|
||||
{ \
|
||||
if( ret == -1 ) \
|
||||
return POLARSSL_ERR_OID_BUF_TOO_SMALL; \
|
||||
\
|
||||
if ( (unsigned int) ret >= n ) { \
|
||||
p[n - 1] = '\0'; \
|
||||
return POLARSSL_ERR_OID_BUF_TOO_SMALL; \
|
||||
} \
|
||||
\
|
||||
n -= (unsigned int) ret; \
|
||||
p += (unsigned int) ret; \
|
||||
#define SAFE_SNPRINTF() \
|
||||
{ \
|
||||
if( ret == -1 ) \
|
||||
return( POLARSSL_ERR_OID_BUF_TOO_SMALL ); \
|
||||
\
|
||||
if ( (unsigned int) ret >= n ) { \
|
||||
p[n - 1] = '\0'; \
|
||||
return( POLARSSL_ERR_OID_BUF_TOO_SMALL ); \
|
||||
} \
|
||||
\
|
||||
n -= (unsigned int) ret; \
|
||||
p += (unsigned int) ret; \
|
||||
}
|
||||
|
||||
/* Return the x.y.z.... style numeric string for the given OID */
|
||||
|
Reference in New Issue
Block a user