mirror of https://github.com/wolfSSL/wolfssl.git
Fix casts depending on OS
parent
a59a3d109f
commit
a1797f0d0d
|
@ -801,7 +801,7 @@ doExit:
|
|||
if (exitWithRet)
|
||||
return err;
|
||||
|
||||
#ifdef __MINGW32__
|
||||
#if defined(__MINGW32__) || defined(_WIN32)
|
||||
#define SIZE_FMT "%d"
|
||||
#define SIZE_TYPE int
|
||||
#else
|
||||
|
@ -852,7 +852,7 @@ static int StartTLS_Init(SOCKET_T* sockfd)
|
|||
}
|
||||
|
||||
/* C: EHLO mail.example.com */
|
||||
if (send(*sockfd, starttlsCmd[1], XSTRLEN(starttlsCmd[1]), 0) !=
|
||||
if (send(*sockfd, starttlsCmd[1], (SIZE_TYPE)XSTRLEN(starttlsCmd[1]), 0) !=
|
||||
(int)XSTRLEN(starttlsCmd[1]))
|
||||
err_sys("failed to send STARTTLS EHLO command\n");
|
||||
|
||||
|
@ -869,7 +869,7 @@ static int StartTLS_Init(SOCKET_T* sockfd)
|
|||
}
|
||||
|
||||
/* C: STARTTLS */
|
||||
if (send(*sockfd, starttlsCmd[3], XSTRLEN(starttlsCmd[3]), 0) !=
|
||||
if (send(*sockfd, starttlsCmd[3], (SIZE_TYPE)XSTRLEN(starttlsCmd[3]), 0) !=
|
||||
(int)XSTRLEN(starttlsCmd[3])) {
|
||||
err_sys("failed to send STARTTLS command\n");
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue