mirror of
https://github.com/cesanta/mongoose.git
synced 2026-11-11 16:40:17 +00:00
silence some compilers
This commit is contained in:
1 parent
c01a1b613f
commit
7d77d8f3d7
2 files changed
+4
-3
No files matched your search
+3
-2
@@ -725,9 +725,10 @@ static int mg_tls_server_recv_hello(struct mg_connection *c) {
|
||||
if (key_exchange_len > n - 2)
|
||||
goto fail;
|
||||
for (k = 0; k < key_exchange_len;) {
|
||||
uint16_t m, group;
|
||||
if ((key_exchange_len - k) < 4) goto fail;
|
||||
uint16_t m = MG_LOAD_BE16(key_exchange + k + 2);
|
||||
uint16_t group = MG_LOAD_BE16(key_exchange + k);
|
||||
m = MG_LOAD_BE16(key_exchange + k + 2);
|
||||
group = MG_LOAD_BE16(key_exchange + k);
|
||||
if (((uint32_t) m + k + 4) > key_exchange_len) goto fail;
|
||||
// secp256r1, uncompressed point 0x04 || X || Y
|
||||
if (group == 0x0017 && m == 65 && key_exchange[k + 4] == 0x04) {
|
||||
|
||||
Reference in new issue
Block a user