Skip to content
Snippets Groups Projects
Commit c4dbe6c5 authored by Libor Peltan's avatar Libor Peltan Committed by Daniel Salzman
Browse files

xfr: give up if one rrset is larger than whole message (fix of infinite loop)

parent 76e59e0b
Branches
Tags
1 merge request!651Huge rrset
......@@ -57,6 +57,12 @@ int xfr_process_list(knot_pkt_t *pkt, xfr_put_cb process_item,
ret = knot_pkt_put(pkt, 0, &soa_rr, KNOT_PF_NOTRUNC);
}
/* If a rrset is larger than the message,
* fail to avoid infinite loop of empty messages */
if (ret == KNOT_ESPACE && pkt->rrset_count < 1) {
return KNOT_ENOXFR;
}
/* Update counters. */
xfr_stats_add(&xfer->stats, pkt->size);
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment