From: Dave Hart Date: Sat, 26 Nov 2011 23:06:48 +0000 (+0000) Subject: more merge cleanup X-Git-Tag: NTP_4_2_7P237~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4ba46aaef2f1b0dc19ddf37d48d2c67c6e5bfc08;p=thirdparty%2Fntp.git more merge cleanup bk: 4ed171086XDfojqB-ikZOhM8db85cQ --- diff --git a/include/lib_strbuf.h b/include/lib_strbuf.h index 3f233288a..5ee92d6f8 100644 --- a/include/lib_strbuf.h +++ b/include/lib_strbuf.h @@ -1,6 +1,8 @@ /* * lib_strbuf.h - definitions for routines which use the common string buffers */ +#ifndef LIB_STRBUF_H +#define LIB_STRBUF_H #include #include /* for ZERO() */ @@ -26,3 +28,5 @@ extern int lib_inited; (bufp) = &lib_stringbuf[lib_nextbuf++][0]; \ lib_nextbuf %= COUNTOF(lib_stringbuf); \ } while (FALSE) + +#endif /* LIB_STRBUF_H */ diff --git a/include/ntp_fp.h b/include/ntp_fp.h index c726748e5..b1e912662 100644 --- a/include/ntp_fp.h +++ b/include/ntp_fp.h @@ -265,7 +265,7 @@ typedef u_int32 u_fp; q_tmp = ~(u_int64)ldexp(-d_tmp, 32) + 1; \ else \ q_tmp = (u_int64)ldexp(d_tmp, 32); \ - (r_uf) = (u_int32)(q_tmp & UINT32_MAX); \ + (r_uf) = (u_int32)(q_tmp & U_INT32_MAX); \ (r_ui) = (u_int32)(q_tmp >> 32); \ } while(0) diff --git a/include/ntp_types.h b/include/ntp_types.h index 4c5e3f42a..363dd7d30 100644 --- a/include/ntp_types.h +++ b/include/ntp_types.h @@ -63,22 +63,22 @@ typedef unsigned int u_int; #ifdef HAVE_UINT32_T # ifndef HAVE_INT32 typedef int32_t int32; -# ifndef INT32_MIN -# define INT32_MIN INT32_T_MIN -# endif -# ifndef INT32_MAX -# define INT32_MAX INT32_T_MAX -# endif # endif # ifndef HAVE_U_INT32 typedef uint32_t u_int32; -# define U_INT32_MAX UINT32_T_MAX +# ifndef U_INT32_MAX +# define U_INT32_MAX UINT32_MAX +# endif # endif #elif (SIZEOF_INT == 4) # if !defined(HAVE_INT32) && !defined(int32) typedef int int32; -# define INT32_MIN INT_MIN -# define INT32_MAX INT_MAX +# ifndef INT32_MIN +# define INT32_MIN INT_MIN +# endif +# ifndef INT32_MAX +# define INT32_MAX INT_MAX +# endif # endif # if !defined(HAVE_U_INT32) && !defined(u_int32) typedef unsigned u_int32; @@ -108,8 +108,8 @@ typedef unsigned int u_int; # endif #endif /* !HAVE_UINT32_T && SIZEOF_INT != 4 */ -#ifndef UINT32_MAX -#define UINT32_MAX 0xffffffff +#ifndef U_INT32_MAX +#define U_INT32_MAX 0xffffffff #endif