فهرست منبع

[check_dns] Update IF_RECORD to not erase query_found.
Fixes issue #115

Bill Blough 10 سال پیش
والد
کامیت
bfe7f8c360
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      plugins/check_dns.c

+ 1 - 1
plugins/check_dns.c

@@ -33,7 +33,7 @@
       temp_buffer = rindex (chld_out.line[i], ' '); \
       addresses[n_addresses++] = check_new_address(temp_buffer); \
       strncpy(query_found, querytype, sizeof(query_found)); \
-      memset(query_found, '\0', sizeof(query_found));
+      query_found[sizeof(querytype)] = '\0';
 
 const char *progname = "check_dns";
 const char *copyright = "2000-2014";