[collectd] DNS plugin bug and patch

Süttő Dániel sutto.daniel at itk.ppke.hu
Fri May 4 15:11:37 CEST 2012


Hi,

as I have already written, there is a bug in DNS plugin.
There is a typo in UDP_SRC definition in utils_dns.c.

Here is the patch:
--- src/utils_dns.c.orig	2012-04-02 10:04:58.000000000 +0200
+++ src/utils_dns.c.fixed	2012-05-04 11:35:52.046802655 +0200
@@ -119,9 +119,9 @@
 #if HAVE_STRUCT_UDPHDR_UH_DPORT && HAVE_STRUCT_UDPHDR_UH_SPORT
 # define UDP_DEST uh_dport
-# define UDP_SRC  uh_dport
+# define UDP_SRC  uh_sport
 #elif HAVE_STRUCT_UDPHDR_DEST && HAVE_STRUCT_UDPHDR_SOURCE
 # define UDP_DEST dest
 # define UDP_SRC  source
 #else
 # error "`struct udphdr' is unusable."
 #endif

Could you fix it please?

--
Dániel SÜTTŐ
PPKE ITK
sutto.daniel at itk.ppke.hu



More information about the collectd mailing list