[Libreoffice-commits] core.git: Branch 'libreoffice-4-3' - oox/source

Caolán McNamara caolanm at redhat.com
Thu Dec 4 08:48:49 PST 2014


 oox/source/vml/vmlformatting.cxx |   10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

New commits:
commit 9a63f1baddecb61f92eeadc484ac31fffdbc4bbf
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Dec 2 14:51:09 2014 +0000

    Resolves: fdo#70157 fix crash on loading
    
    Change-Id: I0d248a195852c14cd95d4e337823076dd2fbc19d
    (cherry picked from commit 8302d048653d9ac25d3cb9ab9277df715053ad6a)
    (cherry picked from commit a757e1b1300dde12fb865c1efd64bfd2bef00e2c)
    Reviewed-on: https://gerrit.libreoffice.org/13272
    Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>
    Tested-by: Miklos Vajna <vmiklos at collabora.co.uk>

diff --git a/oox/source/vml/vmlformatting.cxx b/oox/source/vml/vmlformatting.cxx
index 86b303e..8fca88d 100644
--- a/oox/source/vml/vmlformatting.cxx
+++ b/oox/source/vml/vmlformatting.cxx
@@ -378,9 +378,13 @@ void ConversionHelper::decodeVmlPath( ::std::vector< ::std::vector< Point > >& r
                     break;
 
                 case CLOSE: // 0 param
-                    rPointLists.back().push_back( rPointLists.back()[ 0 ] );
-                    rFlagLists.back().push_back( rFlagLists.back()[ 0 ] );
-                    aCurrentPoint = rPointLists.back().back();
+                    SAL_WARN_IF(rPointLists.back().empty() || rPointLists.back().empty(), "oox", "empty pointlists at close");
+                    if (!rPointLists.back().empty() && !rFlagLists.back().empty())
+                    {
+                        rPointLists.back().push_back( rPointLists.back()[ 0 ] );
+                        rFlagLists.back().push_back( rFlagLists.back()[ 0 ] );
+                        aCurrentPoint = rPointLists.back().back();
+                    }
                     break;
 
                 case END: // 0 param


More information about the Libreoffice-commits mailing list