浏览代码

dns cache: fix dns_cache_delete_single_record()

Binary comparison is needed to check the flags.
Miklos Tirpak 15 年之前
父节点
当前提交
a1dea0ec1d
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      dns_cache.c

+ 1 - 1
dns_cache.c

@@ -4539,7 +4539,7 @@ int dns_cache_delete_single_record(unsigned short type,
 	)
 		goto not_found;
 
-	if (flags && DNS_FLAG_BAD_NAME) /* negative record, there is no value */
+	if (flags & DNS_FLAG_BAD_NAME) /* negative record, there is no value */
 		goto delete;
 
 	/* check whether there is an rr with the same value */