diff --git a/src/chinadns.c b/src/chinadns.c index 6716554..4674f67 100644 --- a/src/chinadns.c +++ b/src/chinadns.c @@ -797,13 +797,19 @@ static int should_filter_query(ns_msg msg, struct in_addr dns_addr) { if (bidirectional) { // filter DNS result from foreign dns if result is inside chn return 1; + } else { + return -1; } + } else { + return 0; } } else { // result is foreign if (dns_is_chn) { // filter DNS result from chn dns if result is outside chn return 1; + } else { + return -1; } } } else if (type == ns_t_aaaa || type == ns_t_ptr) {