host: register unittests

Host unittests were not registered so they wouldn't run.
stream: move utility functions

This way they can be used by the *Inline* functions as well.
stream: improve inline mode GAP handling

Don't conclude a GAP is 'final' until the missing data is ack'd.

Further, cleanup and unify more with the non-inline code.
output-json: fix duplicate logging

This patches is fixing a issue in the OutputJSONBuffer function. It
was writing to file the content of the buffer starting from the start
to the final offset. But as the writing is done for each JSON string
we are duplicating the previous events if we are reusing the same
buffer.

Duplication was for example triggered when we have multiple alerts
attached to a packet. In the case of two alerts, the first one was
logged twice more as the second one.
app-layer: fix 'detection-only' keyword

If we follow the description in the yaml file, we should disable
parsing if 'detection-only' keyword is used.