From 96d5697ed2bf9ab3ec824430c95f10547d6f68ee Mon Sep 17 00:00:00 2001 From: Vincent Bernat Date: Sun, 31 Jan 2016 15:29:56 +0100 Subject: [PATCH] lib: only define ntohll if not already defined --- src/lib/fixedpoint.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/lib/fixedpoint.c b/src/lib/fixedpoint.c index 155fad11..737919cf 100644 --- a/src/lib/fixedpoint.c +++ b/src/lib/fixedpoint.c @@ -28,9 +28,11 @@ #ifdef ENABLE_LLDPMED -#define ntohll(x) \ +#ifndef ntohll +# define ntohll(x) \ (((u_int64_t)(ntohl((int)(((x) << 32) >> 32))) << 32) | \ (unsigned int)ntohl(((int)((x) >> 32)))) +#endif /** * Convert a string to fixed point number. -- 2.39.5