Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates to ldns_is_rrset() #251

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion rr.c
Original file line number Diff line number Diff line change
Expand Up @@ -1264,6 +1264,7 @@ ldns_is_rrset(const ldns_rr_list *rr_list)
{
ldns_rr_type t;
ldns_rr_class c;
uint32_t l;
ldns_rdf *o;
ldns_rr *tmp;
size_t i;
Expand All @@ -1276,6 +1277,7 @@ ldns_is_rrset(const ldns_rr_list *rr_list)

t = ldns_rr_get_type(tmp);
c = ldns_rr_get_class(tmp);
l = ldns_rr_ttl(tmp);
o = ldns_rr_owner(tmp);

/* compare these with the rest of the rr_list, start with 1 */
Expand All @@ -1287,7 +1289,10 @@ ldns_is_rrset(const ldns_rr_list *rr_list)
if (c != ldns_rr_get_class(tmp)) {
return false;
}
if (ldns_rdf_compare(o, ldns_rr_owner(tmp)) != 0) {
if (l != ldns_rr_ttl(tmp)) {
return false;
}
if (ldns_dname_compare(o, ldns_rr_owner(tmp)) != 0) {
return false;
}
}
Expand Down
Loading