stream: minor code cleanup

pull/7787/head
Victor Julien 3 years ago committed by Shivani Bhardwaj
parent 78045d3bbf
commit 55b2077fcd

@ -760,22 +760,10 @@ static inline uint64_t GetLeftEdgeForApp(Flow *f, TcpSession *ssn, TcpStream *st
static inline uint64_t GetLeftEdge(Flow *f, TcpSession *ssn, TcpStream *stream) static inline uint64_t GetLeftEdge(Flow *f, TcpSession *ssn, TcpStream *stream)
{ {
bool use_app = true;
bool use_raw = true;
bool use_log = true;
uint64_t left_edge = 0; uint64_t left_edge = 0;
if ((ssn->flags & STREAMTCP_FLAG_APP_LAYER_DISABLED)) { const bool use_app = !(ssn->flags & STREAMTCP_FLAG_APP_LAYER_DISABLED);
use_app = false; // app is dead const bool use_raw = !(stream->flags & STREAMTCP_STREAM_FLAG_DISABLE_RAW);
} const bool use_log = stream_config.streaming_log_api;
if (stream->flags & STREAMTCP_STREAM_FLAG_DISABLE_RAW) {
use_raw = false; // raw is dead
}
if (!stream_config.streaming_log_api) {
use_log = false;
}
SCLogDebug("use_app %d use_raw %d use_log %d", use_app, use_raw, use_log); SCLogDebug("use_app %d use_raw %d use_log %d", use_app, use_raw, use_log);
if (use_raw) { if (use_raw) {

Loading…
Cancel
Save