]> git.ipfire.org Git - thirdparty/snort3.git/commitdiff
Merge pull request #2173 in SNORT/snort3 from ~DIPANDIT/snort3:stat_issue to master
authorGeorge Koikara (gkoikara) <gkoikara@cisco.com>
Mon, 27 Apr 2020 04:12:24 +0000 (04:12 +0000)
committerGeorge Koikara (gkoikara) <gkoikara@cisco.com>
Mon, 27 Apr 2020 04:12:24 +0000 (04:12 +0000)
Squashed commit of the following:

commit 5d96d28c82120cb6ee2e9babdc844c3f4bb3cacd
Author: Dipto Pandit <dipandit@cisco.com>
Date:   Mon Apr 20 02:28:45 2020 -0400

    file_api: fixing file stats

    file stats were changing each time dump_stats called, as it was never
    reset. clearing the stats when dumping is done.

src/file_api/file_stats.cc

index 829bbcc95900e111e813e00483be271075c6d69b..a6daf47371c3ef5af0e7fb4f531ec20dddd16b2f 100644 (file)
@@ -167,6 +167,8 @@ void file_stats_print()
     LogMessage("            Total          " FMTu64("-10") " " FMTu64("-10") " \n",
         processed_total[0], processed_total[1]);
 
+    memset(&file_totals,0,sizeof(file_totals));
+
 #if 0
     LogLabel("file type verdicts");  // FIXIT-RC should be fixed