mirror of
https://github.com/cesanta/mongoose.git
synced 2026-10-01 05:52:32 +07:00
Bump up max DNS responses 10->15
This commit is contained in:
+1
-1
@@ -720,7 +720,7 @@ bool mg_dns_parse(const uint8_t *buf, size_t len, struct mg_dns_message *dm) {
|
||||
|
||||
if (len < sizeof(*h)) return 0; // Too small, headers dont fit
|
||||
if (mg_ntohs(h->num_questions) > 1) return 0; // Sanity
|
||||
if (mg_ntohs(h->num_answers) > 10) return 0; // Sanity
|
||||
if (mg_ntohs(h->num_answers) > 15) return 0; // Sanity
|
||||
dm->txnid = mg_ntohs(h->txnid);
|
||||
|
||||
for (i = 0; i < mg_ntohs(h->num_questions); i++) {
|
||||
|
||||
@@ -104,7 +104,7 @@ bool mg_dns_parse(const uint8_t *buf, size_t len, struct mg_dns_message *dm) {
|
||||
|
||||
if (len < sizeof(*h)) return 0; // Too small, headers dont fit
|
||||
if (mg_ntohs(h->num_questions) > 1) return 0; // Sanity
|
||||
if (mg_ntohs(h->num_answers) > 10) return 0; // Sanity
|
||||
if (mg_ntohs(h->num_answers) > 15) return 0; // Sanity
|
||||
dm->txnid = mg_ntohs(h->txnid);
|
||||
|
||||
for (i = 0; i < mg_ntohs(h->num_questions); i++) {
|
||||
|
||||
Reference in New Issue
Block a user