Commit Graph

15 Commits (e2f4c751aa1fa7cbf499712b0829f8df61d14787)

Author SHA1 Message Date
Victor Julien 9a4231d737 src: various comment spelling fixes
Thanks to Josh Soref.
4 years ago
Victor Julien 39cf5b151a src: includes cleanup
Work towards making `suricata-common.h` only introduce system headers
and other things that are independent of complex internal Suricata
data structures.

Update files to compile after this.

Remove special DPDK handling for strlcpy and strlcat, as this caused
many compilation failures w/o including DPDK headers for all files.

Remove packet macros from decode.h and move them into their own file,
turn them into functions and rename them to match our function naming
policy.
4 years ago
Sascha Steinbiss 5ec6f3ba51 util: add unit tests for CIDRFromMask() 5 years ago
Sascha Steinbiss 394356f73c detect: make int CIDRFromMask() work on big endian platforms 5 years ago
Victor Julien a67b97e14c util/cidr: add util to convert netmask to cidr 5 years ago
Victor Julien e04d378e58 util/cidr: simplify IPv4 CIDR handling; add IPv6
Instead of building a table at init just calculate it on demand.

Callsites are all during init, so its not performance critical.

Add similar function for IPv6.
5 years ago
Victor Julien ab1200fbd7 compiler: more strict compiler warnings
Set flags by default:

    -Wmissing-prototypes
    -Wmissing-declarations
    -Wstrict-prototypes
    -Wwrite-strings
    -Wcast-align
    -Wbad-function-cast
    -Wformat-security
    -Wno-format-nonliteral
    -Wmissing-format-attribute
    -funsigned-char

Fix minor compiler warnings for these new flags on gcc and clang.
10 years ago
Ken Steele 8f1d75039a Enforce function coding standard
Functions should be defined as:

int foo(void)
{
}

Rather than:
int food(void) {
}

All functions where changed by a script to match this standard.
12 years ago
William Metcalf ce01927515 Import of GPLv2 Header 050410 17 years ago
Victor Julien ecf86f9c23 Rename to Suricata. 17 years ago
Victor Julien 0d0ffb9963 Reorganize header inclusions. 17 years ago
Brian Rectanus fa5939ca91 64 bit cleanup part2 17 years ago
Victor Julien d2b089f359 Fix including the header for htonl breaking the code. 18 years ago
Victor Julien bbbb644dea Add error checking to CIDRGet and make it quiet. 18 years ago
Victor Julien bab4b62376 Initial add of the files. 18 years ago