[Libreoffice-commits] .: svtools/source

Caolán McNamara caolan at kemper.freedesktop.org
Wed Jan 26 12:16:36 PST 2011


 svtools/source/control/ruler.cxx |    3 +++
 1 file changed, 3 insertions(+)

New commits:
commit 308da37739c61c2e23aadc36f92e16d7060219a4
Author: An Leenders <an at Fluffy.(none)>
Date:   Tue Jan 25 17:38:19 2011 +0100

    cpp cleanliness: check for assignment to self

diff --git a/svtools/source/control/ruler.cxx b/svtools/source/control/ruler.cxx
index 340aac4..88e8923 100644
--- a/svtools/source/control/ruler.cxx
+++ b/svtools/source/control/ruler.cxx
@@ -193,6 +193,9 @@ ImplRulerData::~ImplRulerData()
 
 ImplRulerData& ImplRulerData::operator=( const ImplRulerData& rData )
 {
+    if( this == &rData )
+        return *this;
+
     delete[] pLines;
     delete[] pArrows;
     delete[] pBorders;


More information about the Libreoffice-commits mailing list