1
0
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:
Paul Bakker
2014-06-17 14:06:49 +02:00
parent 3c38f29a61
commit d8bb82665e
27 changed files with 256 additions and 256 deletions

View File

@ -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 */