]> git.ipfire.org Git - thirdparty/ntp.git/commitdiff
* [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations).
authorDave Hart <hart@ntp.org>
Thu, 13 May 2010 15:39:47 +0000 (15:39 +0000)
committerDave Hart <hart@ntp.org>
Thu, 13 May 2010 15:39:47 +0000 (15:39 +0000)
bk: 4bec1d43GvOZaJbV3dwYtcB1WYrZkQ

ChangeLog
sntp/networking.c

index 74205bd7aef0c411a1893e835bb88fddce4f2de1..c9f9f77a717f3f25735b28c195d8a6e2aebb582f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+---
+
+* [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations).
+
 ---
 (4.2.6p2-RC3) 2010/05/11 Released by Harlan Stenn <stenn@ntp.org>
 
index 91f3a284ba0b33cfbd42b737e42cf43b82012e72..92b699cc6f73b78c43b75ed155fc7095ca94465a 100644 (file)
@@ -1,3 +1,4 @@
+#include <config.h>
 #include "networking.h"
 
 char adr_buf[INET6_ADDRSTRLEN];
@@ -171,6 +172,10 @@ recv_bcst_data (
        GETSOCKNAME_SOCKLEN_TYPE ss_len;
        struct timeval timeout_tv;
        fd_set bcst_fd;
+#ifdef MCAST
+       struct ip_mreq mdevadr;
+       TYPEOF_IP_MULTICAST_LOOP mtrue = 1;
+#endif
 
        setsockopt(rsock, SOL_SOCKET, SO_REUSEADDR, &btrue, sizeof(btrue));
        if (IS_IPV4(sas)) {
@@ -181,9 +186,6 @@ recv_bcst_data (
                }
 
 #ifdef MCAST
-               struct ip_mreq mdevadr;
-               TYPEOF_IP_MULTICAST_LOOP mtrue = 1;
-
                if (setsockopt(rsock, IPPROTO_IP, IP_MULTICAST_LOOP, &mtrue, sizeof(mtrue)) < 0) {
                        /* some error message regarding setting up multicast loop */
                        return BROADCAST_FAILED;