From b4533338ef5711c48e755c6a5c398811157ddbb9 Mon Sep 17 00:00:00 2001 From: rbuj Date: Wed, 24 Feb 2021 17:27:20 +0100 Subject: proctable: Function 'proctable_free_table' used prior to declaration --- src/proctable.cpp | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'src/proctable.cpp') diff --git a/src/proctable.cpp b/src/proctable.cpp index faab2b0..2cb10c8 100644 --- a/src/proctable.cpp +++ b/src/proctable.cpp @@ -1124,6 +1124,16 @@ proctable_update (ProcData * const procdata) } +void +proctable_free_table (ProcData * const procdata) +{ + for (ProcInfo::Iterator it(ProcInfo::begin()); it != ProcInfo::end(); ++it) + delete it->second; + + ProcInfo::all.clear(); +} + + void proctable_clear_tree (ProcData * const procdata) { @@ -1139,17 +1149,6 @@ proctable_clear_tree (ProcData * const procdata) } -void -proctable_free_table (ProcData * const procdata) -{ - for (ProcInfo::Iterator it(ProcInfo::begin()); it != ProcInfo::end(); ++it) - delete it->second; - - ProcInfo::all.clear(); -} - - - char* make_loadavg_string(void) { -- cgit v1.2.1