Can't check a size_t for < 0.
This commit is contained in:
parent
a6bbbf2ff5
commit
517dd307f9
@ -1393,7 +1393,9 @@ unsigned char *ssl_add_clienthello_tlsext(SSL *s, unsigned char *p, unsigned cha
|
|||||||
const unsigned short ext_len = 2;
|
const unsigned short ext_len = 2;
|
||||||
const unsigned char list_len = 1;
|
const unsigned char list_len = 1;
|
||||||
|
|
||||||
if ((lenmax = limit - ret - 6) < 0) return NULL;
|
if (limit < ret + 6)
|
||||||
|
return NULL;
|
||||||
|
lenmax = limit - ret - 6;
|
||||||
|
|
||||||
s2n(TLSEXT_TYPE_server_authz, ret);
|
s2n(TLSEXT_TYPE_server_authz, ret);
|
||||||
/* Extension length: 2 bytes */
|
/* Extension length: 2 bytes */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user