]> git.ipfire.org Git - thirdparty/ntp.git/commitdiff
remove -dev-only remains of earlier [Bug 1764] fix from
authorDave Hart <hart@ntp.org>
Fri, 31 Dec 2010 23:55:50 +0000 (23:55 +0000)
committerDave Hart <hart@ntp.org>
Fri, 31 Dec 2010 23:55:50 +0000 (23:55 +0000)
  ntpd/refclock_conf.c

bk: 4d1e6d86c-KDecKxnB1Ark8fki9Chw

include/ntpd.h
ntpd/ntp_util.c
ntpd/refclock_conf.c

index 3bd9755636ff344b5b91b30196699b984263574a..ddbb8c7028760b0fea78c515be03f2961484415b 100644 (file)
@@ -8,9 +8,9 @@
  * Each half is further divided into sections for each source file.
  */
 
-#include "ntp_syslog.h"
-#include "ntp_fp.h"
 #include "ntp.h"
+#include "ntp_stdlib.h"
+#include "ntp_syslog.h"
 #include "ntp_debug.h"
 #include "ntp_select.h"
 #include "ntp_malloc.h"
@@ -295,7 +295,8 @@ extern      void    record_peer_stats (sockaddr_u *, int, double, double, double, double
 extern void    record_proto_stats (char *);
 extern void    record_loop_stats (double, double, double, double, int);
 extern void    record_clock_stats (sockaddr_u *, const char *);
-extern int     mprintf_clock_stats(sockaddr_u *, const char *, ...);
+extern int     mprintf_clock_stats(sockaddr_u *, const char *, ...)
+                       __attribute__((__format__(__printf__, 2, 3)));
 extern void    record_raw_stats (sockaddr_u *, sockaddr_u *, l_fp *, l_fp *, l_fp *, l_fp *);
 extern u_long  leap_month(u_long);
 extern void    record_crypto_stats (sockaddr_u *, const char *);
index 85a3f7b1d078805c62f7a370401d60d9157b60a4..ed422129c205bb2cd0a33287636f9de7bfb1c1b7 100644 (file)
@@ -698,12 +698,11 @@ mprintf_clock_stats(
        int     rc;
        char    msg[512];
 
-       if (!stats_control)
-               return;
        va_start(ap, fmt);
        rc = mvsnprintf(msg, sizeof(msg), fmt, ap);
        va_end(ap);
-       record_clock_stats(addr, msg);
+       if (stats_control)
+               record_clock_stats(addr, msg);
 
        return rc;
 }
index 8b1e3044c6a12c203bece49055cf0f34ad2f6def..845e913f77c06ff9a028a9cd3e5933e11bd47087 100644 (file)
@@ -7,12 +7,6 @@
 
 #include <stdio.h>
 #include <sys/types.h>
-#ifdef HAVE_TERMIOS_H
-# include <termios.h>
-#endif
-#ifdef HAVE_SYS_IOCTL_H
-# include <sys/ioctl.h>                /* TIOCMSET here in recent Linux */
-#endif
 
 #include "ntpd.h"
 #include "ntp_refclock.h"