memset (&fp, 0, sizeof (fp));
if (pcap_compile (pcap_obj, &fp, "udp port 53", 1, 0) < 0)
{
- DEBUG ("pcap_compile failed");
ERROR ("dns plugin: pcap_compile failed");
return (NULL);
}
if (pcap_setfilter (pcap_obj, &fp) < 0)
{
- DEBUG ("pcap_setfilter failed");
ERROR ("dns plugin: pcap_setfilter failed");
return (NULL);
}
if (sock_descr < 0)
{
- DEBUG ("Unable to connect to server.");
ERROR ("ntpd plugin: Unable to connect to server.");
}
sizeof (sa.sun_path) - 1);
/* unlink (sa.sun_path); */
+ DEBUG ("unixsock plugin: socket path = %s", sa.sun_path);
+
status = bind (sock_fd, (struct sockaddr *) &sa, sizeof (sa));
if (status != 0)
{
char errbuf[1024];
sstrerror (errno, errbuf, sizeof (errbuf));
- DEBUG ("bind failed: %s; sa.sun_path = %s", errbuf, sa.sun_path);
ERROR ("unixsock plugin: bind failed: %s", errbuf);
close (sock_fd);
sock_fd = -1;