]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
Global define of MIN
authorVictor Julien <victor@inliniac.net>
Mon, 8 Dec 2014 09:40:17 +0000 (10:40 +0100)
committerVictor Julien <victor@inliniac.net>
Thu, 15 Jan 2015 10:52:02 +0000 (11:52 +0100)
Some OS' provide it automatically, so make sure we define it
conditionally in one place.

src/suricata-common.h

index 9aafa7aa35839d77c3ac55e68fbd6488b7f62335..deb0e077cc8346e07581cabc27c52ee206e34964 100644 (file)
 #define pcre_free_study pcre_free
 #endif
 
+#ifndef MIN
+#define MIN(x, y) (((x)<(y))?(x):(y))
+#endif
+
 typedef enum PacketProfileDetectId_ {
     PROF_DETECT_MPM,
     PROF_DETECT_MPM_PACKET,         /* PKT MPM */