mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-30 14:07:59 +00:00
simplify
This commit is contained in:
parent
75167fb746
commit
26f652d387
@ -1411,7 +1411,6 @@ dns_dnssec_findmatchingkeys2(dns_name_t *origin, const char *directory,
|
||||
isc_stdtime_t now, isc_mem_t *mctx,
|
||||
dns_dnsseckeylist_t *keylist)
|
||||
{
|
||||
const char *digits = "0123456789";
|
||||
isc_result_t result = ISC_R_SUCCESS;
|
||||
isc_boolean_t dir_open = ISC_FALSE;
|
||||
dns_dnsseckeylist_t list;
|
||||
@ -1445,11 +1444,10 @@ dns_dnssec_findmatchingkeys2(dns_name_t *origin, const char *directory,
|
||||
|
||||
alg = 0;
|
||||
for (i = len + 1 + 1; i < dir.entry.length ; i++) {
|
||||
const char *digit = strchr(digits, dir.entry.name[i]);
|
||||
if (digit == NULL)
|
||||
if (dir.entry.name[i] < '0' || dir.entry.name[i] > '9')
|
||||
break;
|
||||
alg *= 10;
|
||||
alg += (int)(digit - digits);
|
||||
alg += dir.entry.name[i] - '0';
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
x
Reference in New Issue
Block a user