From 8348e2cbf34d68fb39ebd279d72a2fc85dafe101 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sat, 19 Feb 2005 16:35:00 +0000 Subject: [PATCH] fix operator=() (patch 1126195) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32191 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/xti.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/wx/xti.h b/include/wx/xti.h index 3bf18e703d..2eb3e35e22 100644 --- a/include/wx/xti.h +++ b/include/wx/xti.h @@ -668,7 +668,8 @@ public : wxxVariant& operator=(const wxxVariant &d) { - m_data = d.m_data->Clone() ; + delete m_data; + m_data = d.m_data ? d.m_data->Clone() : NULL ; m_name = d.m_name ; return *this ; }