From a77f390ae35bd6e70200a9cfecf88c2124ab44a6 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 5 Apr 2021 16:32:34 +0200 Subject: [PATCH] Fix wxFileHistory memory leak in the sample We need to delete the object we allocate. --- samples/menu/menu.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/samples/menu/menu.cpp b/samples/menu/menu.cpp index 53f3c0deb5..f186b34966 100644 --- a/samples/menu/menu.cpp +++ b/samples/menu/menu.cpp @@ -748,6 +748,7 @@ MyFrame::MyFrame() MyFrame::~MyFrame() { + delete m_fileHistory; delete m_menu; // delete the event handler installed in ctor