mirror of
https://github.com/NLnetLabs/unbound.git
synced 2026-09-30 21:54:57 +02:00
- Fix testpkts.c, check if DO bit is set, not only if there is an OPT record.
git-svn-id: file:///svn/unbound/trunk@4031 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
+2
-2
@@ -802,8 +802,8 @@ get_do_flag(uint8_t* pkt, size_t len)
|
||||
uint16_t edns_bits;
|
||||
uint8_t* walk = pkt;
|
||||
size_t walk_len = len;
|
||||
if(pkt_find_edns_opt(&walk, &walk_len)) {
|
||||
return 1;
|
||||
if(!pkt_find_edns_opt(&walk, &walk_len)) {
|
||||
return 0;
|
||||
}
|
||||
if(walk_len < 6)
|
||||
return 0; /* malformed */
|
||||
|
||||
Reference in New Issue
Block a user