/*
* This might be the closest enclosing name.
*/
- if (DATA(current) != NULL ||
- (options & DNS_RBTFIND_EMPTYDATA) != 0)
+ if ((options & DNS_RBTFIND_EMPTYDATA) != 0 ||
+ DATA(current) != NULL)
+ {
*node = current;
+ }
/*
* Point the chain to the next level. This
* ISC_R_SUCCESS to indicate an exact match.
*/
if (current != NULL && (options & DNS_RBTFIND_NOEXACT) == 0 &&
- (DATA(current) != NULL ||
- (options & DNS_RBTFIND_EMPTYDATA) != 0)) {
+ ((options & DNS_RBTFIND_EMPTYDATA) != 0 || DATA(current) != NULL))
+ {
/*
* Found an exact match.
*/