projects
/
collectd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'collectd-4.6' into collectd-4.7
[collectd.git]
/
src
/
dns.c
diff --git
a/src/dns.c
b/src/dns.c
index
d82cbd8
..
8339377
100644
(file)
--- a/
src/dns.c
+++ b/
src/dns.c
@@
-19,6
+19,8
@@
* Florian octo Forster <octo at verplant.org>
**/
* Florian octo Forster <octo at verplant.org>
**/
+#define _BSD_SOURCE
+
#include "collectd.h"
#include "common.h"
#include "plugin.h"
#include "collectd.h"
#include "common.h"
#include "plugin.h"
@@
-195,7
+197,7
@@
static void dns_child_callback (const rfc1035_header_t *dns)
pthread_mutex_unlock (&opcode_mutex);
}
pthread_mutex_unlock (&opcode_mutex);
}
-static void *dns_child_loop (void *dummy)
+static void *dns_child_loop (void
__attribute__((unused))
*dummy)
{
pcap_t *pcap_obj;
char pcap_error[PCAP_ERRBUF_SIZE];
{
pcap_t *pcap_obj;
char pcap_error[PCAP_ERRBUF_SIZE];
@@
-212,7
+214,7
@@
static void *dns_child_loop (void *dummy)
/* Passing `pcap_device == NULL' is okay and the same as passign "any" */
DEBUG ("Creating PCAP object..");
/* Passing `pcap_device == NULL' is okay and the same as passign "any" */
DEBUG ("Creating PCAP object..");
- pcap_obj = pcap_open_live (
pcap_device
,
+ pcap_obj = pcap_open_live (
(pcap_device != NULL) ? pcap_device : "any"
,
PCAP_SNAPLEN,
0 /* Not promiscuous */,
interval_g,
PCAP_SNAPLEN,
0 /* Not promiscuous */,
interval_g,