From ff965424c2bc82cba4380a785b1a22c3249686fd Mon Sep 17 00:00:00 2001 From: Clifford Wolf Date: Tue, 6 Aug 2013 15:03:46 +0200 Subject: [PATCH] Added proper deallocation of history buffer --- kernel/driver.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/kernel/driver.cc b/kernel/driver.cc index 0bb12f94d..8765c8b87 100644 --- a/kernel/driver.cc +++ b/kernel/driver.cc @@ -617,6 +617,11 @@ int main(int argc, char **argv) write_history(history_file.c_str()); } + clear_history(); + HIST_ENTRY **hist_list = history_list(); + if (hist_list != NULL) + free(hist_list); + for (auto f : log_files) if (f != stderr) fclose(f); -- 2.30.2