rpms/openoffice.org/devel openoffice.org-3.1.0.ooo100942.svtools.oversafeemf.patch, NONE, 1.1 openoffice.org.spec, 1.1871, 1.1872
Caolan McNamara
caolanm at fedoraproject.org
Wed Apr 8 11:39:39 UTC 2009
Author: caolanm
Update of /cvs/pkgs/rpms/openoffice.org/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv16657
Modified Files:
openoffice.org.spec
Added Files:
openoffice.org-3.1.0.ooo100942.svtools.oversafeemf.patch
Log Message:
Resolves: rhbz#494643 EMF polypolygons issue
openoffice.org-3.1.0.ooo100942.svtools.oversafeemf.patch:
--- NEW FILE openoffice.org-3.1.0.ooo100942.svtools.oversafeemf.patch ---
Index: source/filter.vcl/wmf/enhwmf.cxx
===================================================================
RCS file: /cvs/util/svtools/source/filter.vcl/wmf/enhwmf.cxx,v
retrieving revision 1.39.114.1
diff -u -r1.39.114.1 enhwmf.cxx
--- openoffice.org.orig/svtools/source/filter.vcl/wmf/enhwmf.cxx 26 Sep 2008 11:25:35 -0000 1.39.114.1
+++ openoffice.org/svtools/source/filter.vcl/wmf/enhwmf.cxx 8 Apr 2009 11:25:53 -0000
@@ -378,7 +378,7 @@
// Anzahl der Polygone:
*pWMF >> nPoly >> nGesPoints;
- if ( ( nGesPoints < SAL_MAX_UINT32 / sizeof(Point) ) && ( nPoly < SAL_MAX_UINT32 / sizeof(UINT16) ) )
+ if ( ( nGesPoints < SAL_MAX_UINT32 / (sizeof(sal_uInt16) + sizeof(sal_uInt16)) ) && ( nPoly < SAL_MAX_UINT32 / sizeof(UINT16) ) )
{
if ( ( nPoly * sizeof(UINT16) ) <= ( nEndPos - pWMF->Tell() ) )
{
@@ -390,10 +390,10 @@
pnPoints[ i ] = (UINT16)nPoints;
}
- if ( ( nGesPoints * sizeof(Point) ) <= ( nEndPos - pWMF->Tell() ) )
+ if ( ( nGesPoints * (sizeof(sal_uInt16) + sizeof(sal_uInt16)) ) <= ( nEndPos - pWMF->Tell() ) )
{
// Polygonpunkte holen:
- pPtAry = (Point*) new char[ nGesPoints * sizeof(Point) ];
+ pPtAry = new Point[ nGesPoints ];
for ( i = 0; i < nGesPoints; i++ )
{
@@ -403,7 +403,7 @@
// PolyPolygon Actions erzeugen
PolyPolygon aPolyPoly( (UINT16)nPoly, pnPoints, pPtAry );
pOut->DrawPolyPolygon( aPolyPoly, bRecordPath );
- delete[] (char*) pPtAry;
+ delete[] pPtAry;
}
delete[] pnPoints;
}
@@ -1147,7 +1147,7 @@
pWMF->SeekRel( 0x10 );
// Anzahl der Polygone:
*pWMF >> nPoly >> nGesPoints;
- if ( ( nGesPoints < SAL_MAX_UINT32 / sizeof(Point) ) && ( nPoly < SAL_MAX_UINT32 / sizeof(UINT16) ) )
+ if ( ( nGesPoints < SAL_MAX_UINT32 / (sizeof(sal_uInt16) + sizeof(sal_uInt16)) ) && ( nPoly < SAL_MAX_UINT32 / sizeof(UINT16) ) )
{
if ( ( static_cast< sal_uInt32 >( nPoly ) * sizeof( UINT16 ) ) <= ( nEndPos - pWMF->Tell() ) )
{
@@ -1157,10 +1157,10 @@
*pWMF >> nPoints;
pnPoints[ i ] = (UINT16)nPoints;
}
- if ( ( nGesPoints * sizeof(Point) ) <= ( nEndPos - pWMF->Tell() ) )
+ if ( ( nGesPoints * (sizeof(sal_uInt16)+sizeof(sal_uInt16)) ) <= ( nEndPos - pWMF->Tell() ) )
{
// Polygonpunkte holen:
- pPtAry = (Point*) new char[ nGesPoints * sizeof(Point) ];
+ pPtAry = new Point[ nGesPoints ];
for ( i = 0; i < nGesPoints; i++ )
{
*pWMF >> nX16 >> nY16;
@@ -1170,7 +1170,7 @@
// PolyPolygon Actions erzeugen
PolyPolygon aPolyPoly( (UINT16)nPoly, pnPoints, pPtAry );
pOut->DrawPolyPolygon( aPolyPoly, bRecordPath );
- delete[] (char*) pPtAry;
+ delete[] pPtAry;
}
delete[] pnPoints;
}
Index: openoffice.org.spec
===================================================================
RCS file: /cvs/pkgs/rpms/openoffice.org/devel/openoffice.org.spec,v
retrieving revision 1.1871
retrieving revision 1.1872
diff -u -r1.1871 -r1.1872
--- openoffice.org.spec 8 Apr 2009 08:49:57 -0000 1.1871
+++ openoffice.org.spec 8 Apr 2009 11:39:06 -0000 1.1872
@@ -131,6 +131,7 @@
Patch56: ooo-build.ooo2497.filter.svg.patch
Patch57: openoffice.org-3.1.0.ooo100353.svx.rtfbrackets.patch
Patch58: openoffice.org-3.1.0.ooo100225.comphelper.vis.patch
+Patch59: openoffice.org-3.1.0.ooo100942.svtools.oversafeemf.patch
%define python_py_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(0)")
%define instdir %{_libdir}
@@ -1621,6 +1622,7 @@
%patch56 -p1 -b .ooo2497.filter.svg.patch
%patch57 -p0 -b .ooo100353.svx.rtfbrackets.patch
%patch58 -p0 -b .ooo100225.comphelper.vis.patch
+%patch59 -p1 -b .ooo100942.svtools.oversafeemf.patch
%build
echo build start time is `date`, diskspace: `df -h . | tail -n 1`
@@ -4111,6 +4113,7 @@
* Wed Apr 08 2009 Caolán McNamara <caolanm at redhat.com> - 1:3.1.0-9.2
- Require hyphen-bn, hyphen-te, hyphen-ta, hyphen-pa, hyphen-or,
hyphen-ml, hyphen-kn, hyphen-gu, hyphen-hi
+- Resolves: rhbz#494643 EMF polypolygons issue
* Thu Apr 02 2009 Caolán McNamara <caolanm at redhat.com> - 1:3.1.0-9.1
- latest milestone
More information about the scm-commits
mailing list