mirror of
https://gitlab.isc.org/isc-projects/kea
synced 2025-08-31 14:05:33 +00:00
[1579] more cleanups, mostly editorial ones.
- indentation - spelling: 'other else' should be 'otherwise' - constify - avoid using an unnecessary temporary variable
This commit is contained in:
@@ -666,8 +666,8 @@ DatabaseClient::Finder::findWildcardMatch(const isc::dns::Name& name,
|
||||
LOG_DEBUG(logger, DBG_TRACE_DETAILED,
|
||||
DATASRC_DATABASE_WILDCARD_EMPTY).
|
||||
arg(accessor_->getDBName()).arg(wildcard).arg(name);
|
||||
FindResultFlags flags = (RESULT_WILDCARD |
|
||||
dnssec_ctx.getResultFlags());
|
||||
const FindResultFlags flags = (RESULT_WILDCARD |
|
||||
dnssec_ctx.getResultFlags());
|
||||
if (dnssec_ctx.isNSEC()) {
|
||||
ConstRRsetPtr nsec = findNSECCover(Name(wildcard));
|
||||
if (nsec) {
|
||||
@@ -812,11 +812,10 @@ DatabaseClient::Finder::FindDNSSECContext::getDNSSECRRset(const Name& name,
|
||||
isc_throw(DataSourceError, "no Finder to query");
|
||||
}
|
||||
const bool is_origin = isOrigin(name);
|
||||
bool is_nsec = isNSEC();
|
||||
WantedTypes final_types(is_nsec ? FINAL_TYPES() : FINAL_TYPES_NO_NSEC());
|
||||
WantedTypes final_types(isNSEC() ? FINAL_TYPES() : FINAL_TYPES_NO_NSEC());
|
||||
final_types.insert(type);
|
||||
return (finderp_->getRRsets(name.toText(), final_types, !is_origin, NULL,
|
||||
type == RRType::ANY()));
|
||||
type == RRType::ANY()));
|
||||
}
|
||||
|
||||
bool
|
||||
@@ -836,7 +835,7 @@ DatabaseClient::Finder::FindDNSSECContext::getResultFlags() {
|
||||
return (RESULT_NSEC3_SIGNED);
|
||||
} else {
|
||||
// If it is a DNSSEC query and the zone is signed with NSEC, it should
|
||||
// return RESULT_NSEC_SIGNED, other else, return RESULT_DEFAULT
|
||||
// return RESULT_NSEC_SIGNED, otherwise, return RESULT_DEFAULT
|
||||
return (isNSEC() ? RESULT_NSEC_SIGNED : RESULT_DEFAULT);
|
||||
}
|
||||
}
|
||||
|
@@ -693,7 +693,7 @@ public:
|
||||
///
|
||||
/// Get the ResultFlags for findInterval. If the zone is signed with
|
||||
/// NSEC3, it will return RESULT_NSEC3_SIGNED. If it is signed with
|
||||
/// NSEC, it wll return RESULT_NSEC_SIGNED. Other else it will return
|
||||
/// NSEC, it wll return RESULT_NSEC_SIGNED. Otherwise it will return
|
||||
/// RESULT_DEFAULT. It wraps getRRsets function to do some special
|
||||
/// search, like searching NSEC RRset by getNSECRRset function,
|
||||
/// searching DNSSEC related RRset and RRsig by getNSECRRset.
|
||||
@@ -753,17 +753,17 @@ public:
|
||||
/// \brief Check whether the zone file is signed with NSECi3.
|
||||
///
|
||||
/// It checks whether the zone file is signed with NSEC3. If
|
||||
/// yes, return true, other else return false.
|
||||
/// yes, return true, otherwise return false.
|
||||
///
|
||||
/// \return True for NSEC3, false for other else.
|
||||
/// \return True for NSEC3, false otherwise.
|
||||
bool isNSEC3();
|
||||
|
||||
/// \brief Check whether the zone file is signed with NSEC.
|
||||
///
|
||||
/// It checks whether the zone file is signed with NSEC, If
|
||||
/// yes, return true, other else return false.
|
||||
/// yes, return true, otherwise return false.
|
||||
///
|
||||
/// \return True for NSEC, false for other else.
|
||||
/// \return True for NSEC, false otherwise.
|
||||
bool isNSEC();
|
||||
|
||||
/// \brief Check whether the name is origin name of the zone.
|
||||
@@ -788,7 +788,8 @@ public:
|
||||
/// It should init the attributes of this entity. Check whether
|
||||
/// it is the NSEC or NSEC3 zone file if it is a dnssec query.
|
||||
///
|
||||
/// \note If the entity is initalized, no need to init it again.
|
||||
/// \note If the entity is initialized, no need to init it
|
||||
/// again.
|
||||
void init();
|
||||
|
||||
/// \brief Check whether the entity is initalized.
|
||||
|
Reference in New Issue
Block a user