From: Aaron Lipinski Date: Wed, 7 Apr 2021 19:46:26 +0000 (+1200) Subject: export DEFAULT_AF X-Git-Tag: v0.95~6^2~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cf1b9bc7e7e9d46153b91021ca1f102dc0c79ac5;p=thirdparty%2Fmtr.git export DEFAULT_AF --- diff --git a/ui/mtr.c b/ui/mtr.c index 8edca64..23411cb 100644 --- a/ui/mtr.c +++ b/ui/mtr.c @@ -63,13 +63,6 @@ #include "portability/getopt.h" #endif -#ifdef ENABLE_IPV6 -#define DEFAULT_AF AF_UNSPEC -#else -#define DEFAULT_AF AF_INET -#endif - - char *myname; const struct fields data_fields[MAXFLD] = { diff --git a/ui/mtr.h b/ui/mtr.h index 01536f5..92dd8a1 100644 --- a/ui/mtr.h +++ b/ui/mtr.h @@ -32,8 +32,10 @@ /* Typedefs */ #ifdef ENABLE_IPV6 +#define DEFAULT_AF AF_UNSPEC typedef struct in6_addr ip_t; #else +#define DEFAULT_AF AF_INET typedef struct in_addr ip_t; #endif