[Libreoffice-commits] .: sc/source

Kohei Yoshida kohei at kemper.freedesktop.org
Wed Jun 8 21:19:37 PDT 2011


 sc/source/filter/html/htmlpars.cxx |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 4820648fc4abe7984c3c3c35e4c727c5574e8939
Author: Kohei Yoshida <kyoshida at novell.com>
Date:   Thu Jun 9 00:13:21 2011 -0400

    fdo#37673: Fix a crasher during HTML import on Windows.

diff --git a/sc/source/filter/html/htmlpars.cxx b/sc/source/filter/html/htmlpars.cxx
index 5eeed78..b75d1f6 100644
--- a/sc/source/filter/html/htmlpars.cxx
+++ b/sc/source/filter/html/htmlpars.cxx
@@ -1832,7 +1832,7 @@ public:
         @param pTableMap  Pointer to the table map (is allowed to be NULL). */
     explicit            ScHTMLTableIterator( const ScHTMLTableMap* pTableMap );
 
-    inline bool         is() const { return maIter != maEnd; }
+    inline bool         is() const { return mpTableMap && maIter != maEnd; }
     inline ScHTMLTable* operator->() { return maIter->second.get(); }
     inline ScHTMLTable& operator*() { return *maIter->second; }
     inline ScHTMLTableIterator& operator++() { ++maIter; return *this; }
@@ -1840,9 +1840,11 @@ public:
 private:
     ScHTMLTableMap::const_iterator maIter;
     ScHTMLTableMap::const_iterator maEnd;
+    const ScHTMLTableMap* mpTableMap;
 };
 
-ScHTMLTableIterator::ScHTMLTableIterator( const ScHTMLTableMap* pTableMap )
+ScHTMLTableIterator::ScHTMLTableIterator( const ScHTMLTableMap* pTableMap ) :
+    mpTableMap(pTableMap)
 {
     if( pTableMap )
     {


More information about the Libreoffice-commits mailing list