binpac: Adapted binpac to compile with MSVC for Windows environment.

This commit is contained in:
Elad Solomon 2021-04-22 17:36:41 +03:00 committed by Tim Wojtulewicz
parent dd3737b5c8
commit faa1b7abbf
5 changed files with 29 additions and 13 deletions

View file

@ -3,7 +3,9 @@
#ifndef binpac_h
#define binpac_h
#ifndef _MSC_VER
#include <sys/param.h>
#endif
#cmakedefine HOST_BIGENDIAN
#ifdef HOST_BIGENDIAN
@ -136,7 +138,7 @@ inline string strfmt(const char* format, ...)
} // anonymous namespace
#define binpac_fmt(x...) strfmt(x).c_str()
#define binpac_fmt(...) strfmt(__VA_ARGS__).c_str()
class RefCount
{

View file

@ -1,11 +1,11 @@
#include <vector>
class RE_Matcher;
namespace zeek { class RE_Matcher; }
namespace binpac
{
std::vector<RE_Matcher*>* uncompiled_re_matchers = 0;
std::vector<zeek::RE_Matcher*>* uncompiled_re_matchers = 0;
}