From: Michael Altizer Date: Fri, 13 Dec 2019 16:56:16 +0000 (-0500) Subject: sfip: Use REG_TEST-style IP stringification for standalone Catch tests X-Git-Tag: 3.0.0-267~10 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=365649b054d83a5210a89b6476ef3b49c56fe5a0;p=thirdparty%2Fsnort3.git sfip: Use REG_TEST-style IP stringification for standalone Catch tests This fixes 'make check' failing when not built with -DREG_TEST. --- diff --git a/src/sfip/sf_ip.cc b/src/sfip/sf_ip.cc index 94b2f828f..22a59faad 100644 --- a/src/sfip/sf_ip.cc +++ b/src/sfip/sf_ip.cc @@ -424,7 +424,7 @@ const char* snort_inet_ntop(int family, const void* ip_raw, char* buf, int bufsi return buf; } -#ifndef REG_TEST +#if !defined(REG_TEST) && !defined(CATCH_TEST_BUILD) if (!inet_ntop(family, ip_raw, buf, bufsize)) snprintf(buf, bufsize, "ERROR"); #else