Merge pull request #514 from dgarske/fix_arm_cc_warn

Fixes for warnings when cross-compiling with GCC ARM.
This commit is contained in:
toddouska
2016-08-05 10:07:32 -07:00
committed by GitHub
2 changed files with 6 additions and 2 deletions

View File

@ -12320,7 +12320,7 @@ const char* wolfSSL_get_cipher_name_internal(WOLFSSL* ssl)
const char* fullName;
const char* first;
WOLFSSL_CIPHER* cipher;
word32 i;
int i;
if (ssl == NULL) {
WOLFSSL_MSG("Bad argument");
@ -12335,7 +12335,7 @@ const char* wolfSSL_get_cipher_name_internal(WOLFSSL* ssl)
: (XSTRSTR(fullName, "CCM")) ? "CCM"
: NULL; /* normal */
for (i = 0; i < sizeof(cipher_name_idx); i++) {
for (i = 0; i < (int)sizeof(cipher_name_idx); i++) {
if (cipher_name_idx[i] == ssl->options.cipherSuite) {
const char* nameFound = cipher_names[i];
@ -15927,6 +15927,8 @@ int DoSessionTicket(WOLFSSL* ssl,
(void)ssl;
(void)sigSz;
(void)length;
(void)idx;
#ifdef WOLFSSL_ASYNC_CRYPT
ret = wolfSSL_async_pop(ssl, WOLF_EVENT_TYPE_ASYNC_ACCEPT);

View File

@ -253,6 +253,8 @@ static int wc_MGF1(enum wc_HashType hType, byte* seed, word32 seedSz,
counter = 0;
idx = 0;
(void)heap;
/* check error return of wc_HashGetDigestSize */
if (hLen < 0) {
return hLen;