filter/source/flash/swfwriter1.cxx |    3 ---
 1 file changed, 3 deletions(-)

New commits:
commit dcbf6dba50ad25d92018f87402ced06cc22fea6f
Author:     Skyler Grey <[email protected]>
AuthorDate: Wed Nov 6 11:50:14 2024 +0000
Commit:     Caolán McNamara <[email protected]>
CommitDate: Wed Nov 6 17:41:50 2024 +0100

    fix(swfexport): Fix crash on matrix export
    
    Previously, we tried to set row 2 on matrices, which failed on matrices
    without multiple rows, leading to a crash.
    
    This was possibly caused by d0d46e0f506d7fd3578039ed23c9e4235c29ca8f,
    which migrated to B3DHomMatrix from Matrix3D, however B3DHomMatrix has
    the following comment (include/basegfx/matrix/b2dhommatrix.hxx):
    
    // Since this is a graphics matrix, the last row is always 0 0 1, so we 
don't bother to store it.
    
    It therefore seems likely that we incorrectly migrated this, and didn't
    notice for a long while (faulty code is not actually used on all
    documents, so there's a good chance you'll miss it)
    
    Co-Authored-By: Caolán McNamara <[email protected]>
    Change-Id: Ib4ba1ab6c9245190051bbf99628b3e9b28b9c34c
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176146
    Tested-by: Jenkins CollaboraOffice <[email protected]>
    Tested-by: Caolán McNamara <[email protected]>
    Reviewed-by: Caolán McNamara <[email protected]>

diff --git a/filter/source/flash/swfwriter1.cxx 
b/filter/source/flash/swfwriter1.cxx
index 93c797370ace..367202aa9356 100644
--- a/filter/source/flash/swfwriter1.cxx
+++ b/filter/source/flash/swfwriter1.cxx
@@ -1175,9 +1175,6 @@ bool Writer::Impl_writeFilling(SvtGraphicFill const& 
rFilling)
                     aMatrix.set(a, b, aTransform.matrix[a * 3 + b]);
                 }
             }
-            aMatrix.set(2, 0, 0.0);
-            aMatrix.set(2, 1, 0.0);
-            aMatrix.set(2, 2, 1.0);
 
             // scale bitmap
             double XScale = aOldRect.GetWidth()

Reply via email to