1. According to man asprintf:
If memory allocation wasn't possible, or some other error occurs,
these functions will return -1, and the contents of strp is undefined.
2. Sometimes, errp was not filled at all. In high-level code, free(errp)
will called, so segmantation fault may appear in case of error in parser
3. The most cases of using asprintf is to report about allocation fail.
So, probability of allocation of asprintf buffer is very high. And that
will lead to trash in errp.
4. For simple casses I decide to replace asprintf with strdup
- Fixes a bunch of bugs related to ematches
- Adds support for the nbyte ematch
- Adds a bison/flex parser for ematch expressions, expressions
may look like this:
ip.length > 256 && pattern(ip6.src = 3ffe::/16)
documenation on syntax follows
- adds ematch support to the basic classifier (--ematch EXPR)