From 5574f50bf48c1d4cc863960c21d5784b1beef46d Mon Sep 17 00:00:00 2001 From: david Date: Fri, 9 Sep 2011 08:24:47 +0000 Subject: [PATCH] Free TOps_AVs and TWin_AVs between OS rounds. This was leaking a small amount of memory when OS detection was repeated on a host. --- osscan2.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/osscan2.cc b/osscan2.cc index c8ee2a38f..b2fb5e789 100644 --- a/osscan2.cc +++ b/osscan2.cc @@ -1170,6 +1170,10 @@ void HostOsScanStats::initScanStats() { FPtests[i] = NULL; } for (i=0; i<6; i++) { + if (TOps_AVs[i]) + free(TOps_AVs[i]); + if (TWin_AVs[i]) + free(TWin_AVs[i]); TOps_AVs[i] = NULL; TWin_AVs[i] = NULL; }