From: Victor Julien Date: Tue, 23 Oct 2018 10:57:50 +0000 (+0200) Subject: coverity: don't warn on fall back random X-Git-Tag: suricata-4.1.0~44 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a6832791378e37c482ea7062a84da07af5e68df4;p=thirdparty%2Fsuricata.git coverity: don't warn on fall back random --- diff --git a/src/util-random.c b/src/util-random.c index eef70e2c3e..1bade5428b 100644 --- a/src/util-random.c +++ b/src/util-random.c @@ -36,6 +36,7 @@ static long int RandomGetClock(void) struct timespec ts; clock_gettime(CLOCK_REALTIME, &ts); + // coverity[dont_call : FALSE] srandom(ts.tv_nsec ^ ts.tv_sec); long int value = random(); return value; @@ -49,6 +50,7 @@ static long int RandomGetPosix(void) memset(&tv, 0, sizeof(tv)); gettimeofday(&tv, NULL); + // coverity[dont_call : FALSE] srandom(tv.tv_usec ^ tv.tv_sec); long int value = random(); return value;