From a4fca88ba7f70b9697bf8d194dc70526224daa76 Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Fri, 19 Apr 2013 12:15:57 +0200 Subject: [PATCH] stream: default 'random' setting when running unittests is disabled, so that test results are predictable. --- src/stream-tcp.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/stream-tcp.c b/src/stream-tcp.c index e29637512f..d6033c0600 100644 --- a/src/stream-tcp.c +++ b/src/stream-tcp.c @@ -480,8 +480,10 @@ void StreamTcpInitConfig(char quiet) int randomize = 0; if ((ConfGetBool("stream.reassembly.randomize-chunk-size", &randomize)) == 0) { - /* randomize by default if value not set */ - randomize = 1; + /* randomize by default if value not set + * In ut mode we disable, to get predictible test results */ + if (!(RunmodeIsUnittests())) + randomize = 1; } if (randomize) { -- 2.47.3