forked from wolfSSL/wolfssl
fix Windows compile warnings
This commit is contained in:
@ -4105,7 +4105,7 @@ static INLINE int DtlsCheckWindow(DtlsState* state)
|
|||||||
if ((next > DTLS_SEQ_BITS) && (cur < next - DTLS_SEQ_BITS)) {
|
if ((next > DTLS_SEQ_BITS) && (cur < next - DTLS_SEQ_BITS)) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
else if ((cur < next) && (window & (1 << (next - cur - 1)))) {
|
else if ((cur < next) && (window & ((DtlsSeq)1 << (next - cur - 1)))) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4131,7 +4131,7 @@ static INLINE int DtlsUpdateWindow(DtlsState* state)
|
|||||||
cur = state->curSeq;
|
cur = state->curSeq;
|
||||||
|
|
||||||
if (cur < *next) {
|
if (cur < *next) {
|
||||||
*window |= (1 << (*next - cur - 1));
|
*window |= ((DtlsSeq)1 << (*next - cur - 1));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
*window <<= (1 + cur - *next);
|
*window <<= (1 + cur - *next);
|
||||||
@ -8683,7 +8683,7 @@ static void PickHashSigAlgo(CYASSL* ssl,
|
|||||||
|
|
||||||
if (esSz > MAX_PSK_ID_LEN)
|
if (esSz > MAX_PSK_ID_LEN)
|
||||||
return CLIENT_ID_ERROR;
|
return CLIENT_ID_ERROR;
|
||||||
c16toa(esSz, es);
|
c16toa((word16)esSz, es);
|
||||||
es += OPAQUE16_LEN;
|
es += OPAQUE16_LEN;
|
||||||
XMEMCPY(es, ssl->arrays->client_identity, esSz);
|
XMEMCPY(es, ssl->arrays->client_identity, esSz);
|
||||||
es += esSz;
|
es += esSz;
|
||||||
@ -11757,7 +11757,7 @@ static void PickHashSigAlgo(CYASSL* ssl,
|
|||||||
FreeDhKey(&dhKey);
|
FreeDhKey(&dhKey);
|
||||||
|
|
||||||
*inOutIdx += clientSz;
|
*inOutIdx += clientSz;
|
||||||
c16toa(ssl->arrays->preMasterSz, pms);
|
c16toa((word16)ssl->arrays->preMasterSz, pms);
|
||||||
ssl->arrays->preMasterSz += OPAQUE16_LEN;
|
ssl->arrays->preMasterSz += OPAQUE16_LEN;
|
||||||
pms += ssl->arrays->preMasterSz;
|
pms += ssl->arrays->preMasterSz;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user