X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/0b3e395a5c7a61c6bcf08e2c340a7f2de8ba3c37..12bb29f5432174ecbd65549bda832d70d34a98ae:/src/xml/xml.cpp diff --git a/src/xml/xml.cpp b/src/xml/xml.cpp index 6e2dbf6c96..0fc27c246b 100644 --- a/src/xml/xml.cpp +++ b/src/xml/xml.cpp @@ -97,8 +97,12 @@ wxXmlNode::~wxXmlNode() wxXmlNode& wxXmlNode::operator=(const wxXmlNode& node) { - DoFree(); - DoCopy(node); + if ( &node != this ) + { + DoFree(); + DoCopy(node); + } + return *this; }