fix codebase for -Wvla -Wdeclaration-after-statement; fix some whitespace.

This commit is contained in:
Daniel Pouzzner
2022-04-01 14:44:10 -05:00
parent bd0e222fec
commit ae3996fd0e
6 changed files with 300 additions and 239 deletions

View File

@ -10938,7 +10938,6 @@ static int ProcessCSR(WOLFSSL* ssl, byte* input, word32* inOutIdx,
{
int ret = 0;
OcspRequest* request;
WOLFSSL_ENTER("ProcessCSR");
#ifdef WOLFSSL_SMALL_STACK
CertStatus* status;
@ -10950,6 +10949,8 @@ static int ProcessCSR(WOLFSSL* ssl, byte* input, word32* inOutIdx,
OcspResponse response[1];
#endif
WOLFSSL_ENTER("ProcessCSR");
do {
#ifdef HAVE_CERTIFICATE_STATUS_REQUEST
if (ssl->status_request) {

File diff suppressed because it is too large Load Diff

View File

@ -3457,10 +3457,11 @@ int wolfSSL_EVP_PBE_scrypt(const char *pass, size_t passlen,
word64 N, word64 r, word64 p,
word64 maxmem, unsigned char *key, size_t keylen)
{
(void)maxmem;
int ret;
int exp = 0;
(void)maxmem;
WOLFSSL_ENTER("wolfSSL_EVP_PBE_scrypt");
if (r > INT32_MAX || p > INT32_MAX) {

View File

@ -552,7 +552,7 @@ decouple library dependencies with standard string, memory and so on.
#define WC_DECLARE_ARRAY_DYNAMIC_DEC(VAR_NAME, VAR_TYPE, VAR_ITEMS, VAR_SIZE, HEAP) \
VAR_TYPE* VAR_NAME[VAR_ITEMS]; \
int idx##VAR_NAME, inner_idx_##VAR_NAME;
int idx##VAR_NAME, inner_idx_##VAR_NAME
#define WC_DECLARE_ARRAY_DYNAMIC_EXE(VAR_NAME, VAR_TYPE, VAR_ITEMS, VAR_SIZE, HEAP) \
for (idx##VAR_NAME=0; idx##VAR_NAME<(VAR_ITEMS); idx##VAR_NAME++) { \
(VAR_NAME)[idx##VAR_NAME] = (VAR_TYPE*)XMALLOC(VAR_SIZE, (HEAP), DYNAMIC_TYPE_TMP_BUFFER); \