Skip to content

Commit

Permalink
fix numtrunc in str2wire.c and parse error type cases and fix style x2
Browse files Browse the repository at this point in the history
  • Loading branch information
headshog committed Jul 14, 2023
1 parent 8f98c01 commit 3884816
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions sldns/rrdef.c
Original file line number Diff line number Diff line change
Expand Up @@ -702,10 +702,10 @@ sldns_get_rr_type_by_name(const char *name)

/* TYPEXX representation */
if (strlen(name) > 4 && strncasecmp(name, "TYPE", 4) == 0) {
unsigned int a = atoi(name + 4);
if (a > LDNS_RR_TYPE_LAST) {
return LDNS_RR_TYPE_ERROR;
}
unsigned int a = atoi(name + 4);
if (a > LDNS_RR_TYPE_LAST) {
return LDNS_RR_TYPE_ERROR;
}
return a;
}

Expand Down

0 comments on commit 3884816

Please sign in to comment.