From 2e0d1932aa72e3ca2b754597f428c75c75a801d2 Mon Sep 17 00:00:00 2001
From: Vadim Zeitlin <vadim@wxwidgets.org>
Date: Sat, 27 Oct 2007 17:57:13 +0000
Subject: [PATCH] fix memory leak in the usage example

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@49493 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
---
 docs/latex/wx/snglinst.tex | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/docs/latex/wx/snglinst.tex b/docs/latex/wx/snglinst.tex
index 16544113cb..3cae29f168 100644
--- a/docs/latex/wx/snglinst.tex
+++ b/docs/latex/wx/snglinst.tex
@@ -30,6 +30,9 @@ bool MyApp::OnInit()
     {
         wxLogError(_("Another program instance is already running, aborting."));
 
+        delete m_checker; // OnExit() won't be called if we return false
+        m_checker = NULL;
+
         return false;
     }
 
-- 
2.50.0

