[ooo-build-commit] .: 3 commits - patches/dev300

Thorsten Behrens thorsten at kemper.freedesktop.org
Wed Feb 3 04:22:13 PST 2010


 patches/dev300/apply                            |    3 +++
 patches/dev300/sd-avoid-looping-fix.diff        |   21 +++++++++++++++++++++
 patches/dev300/svx-validate-paradepth.diff      |   15 +++++++++++++++
 patches/dev300/vcl-pngread-greypalette-fix.diff |   23 +++++++++++++++++++++++
 4 files changed, 62 insertions(+)

New commits:
commit 088711c3e1508c0644d1c38932d0328d9114f0ee
Author: Thorsten Behrens <tbehrens at novell.com>
Date:   Wed Feb 3 13:10:42 2010 +0100

    Handle corner case in vcl's greypalette init
    
    * patches/dev300/apply: added the patch
    * patches/dev300/vcl-pngread-greypalette-fix.diff: don't divide by
      zero in greypalette init, bail out early in chunk reader

diff --git a/patches/dev300/apply b/patches/dev300/apply
index 9a8d4ac..3df5f75 100644
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -3543,3 +3543,4 @@ sd-sound.diff, n#515553, rodo
 slideshow-sound.diff, n#515553, rodo
 sd-avoid-looping-fix.diff, thorsten
 svx-validate-paradepth.diff, thorsten
+vcl-pngread-greypalette-fix.diff, thorsten
diff --git a/patches/dev300/vcl-pngread-greypalette-fix.diff b/patches/dev300/vcl-pngread-greypalette-fix.diff
new file mode 100644
index 0000000..2f2d2e9
--- /dev/null
+++ b/patches/dev300/vcl-pngread-greypalette-fix.diff
@@ -0,0 +1,23 @@
+diff --git a/vcl/source/gdi/pngread.cxx b/vcl/source/gdi/pngread.cxx
+index fe559f5..de2ddf7 100644
+--- vcl/source/gdi/pngread.cxx
++++ vcl/source/gdi/pngread.cxx
+@@ -376,6 +376,9 @@ BitmapEx PNGReaderImpl::GetBitmapEx( const Size& rPreviewSizeHint )
+     // parse the chunks
+     while( mbStatus && !mbIDAT && ReadNextChunk() )
+     {
++        if( !mbStatus )
++            break;
++
+         switch( mnChunkType )
+         {
+             case PNGCHUNK_IHDR :
+@@ -706,7 +709,7 @@ void PNGReaderImpl::ImplGetGrayPalette( sal_uInt16 nBitDepth )
+         nBitDepth = 8;
+ 
+     sal_uInt16  nPaletteEntryCount = 1 << nBitDepth;
+-    sal_uInt32  nAdd = 256 / (nPaletteEntryCount - 1);
++    sal_uInt32  nAdd = nBitDepth ? 256 / (nPaletteEntryCount - 1) : 0;
+ 
+     // no bitdepth==2 available
+     // but bitdepth==4 with two unused bits is close enough
commit 14589f97249b80001f4d21a3909bcb3b6c030009
Author: Thorsten Behrens <tbehrens at novell.com>
Date:   Wed Feb 3 13:06:36 2010 +0100

    Make sure paradepth is properly initialised
    
    * patches/dev300/apply: added the patch
    * patches/dev300/svx-validate-paradepth.diff: fix a not-so-properly
      initialized paradepth in svdfppt.cxx

diff --git a/patches/dev300/apply b/patches/dev300/apply
index d3f459d..9a8d4ac 100644
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -3541,4 +3541,5 @@ framework-netbook.diff, rodo
 svx-sound.diff, n#515553, rodo
 sd-sound.diff, n#515553, rodo
 slideshow-sound.diff, n#515553, rodo
-sd-avoid-looping-fix.diff, thorsten
\ No newline at end of file
+sd-avoid-looping-fix.diff, thorsten
+svx-validate-paradepth.diff, thorsten
diff --git a/patches/dev300/svx-validate-paradepth.diff b/patches/dev300/svx-validate-paradepth.diff
new file mode 100644
index 0000000..9b74c5b
--- /dev/null
+++ b/patches/dev300/svx-validate-paradepth.diff
@@ -0,0 +1,15 @@
+diff --git a/svx/source/svdraw/svdfppt.cxx b/svx/source/svdraw/svdfppt.cxx
+index 02d2044..c452472 100644
+--- svx/source/svdraw/svdfppt.cxx
++++ svx/source/svdraw/svdfppt.cxx
+@@ -5099,6 +5099,10 @@ void PPTStyleTextPropReader::ReadParaProps( SvStream& rIn, SdrPowerPointImport&
+             rIn >> nCharCount
+                 >> aParaPropSet.pParaSet->mnDepth;	// Einruecktiefe
+ 
++            aParaPropSet.pParaSet->mnDepth = 
++                std::min(sal_uInt16(9),
++                         aParaPropSet.pParaSet->mnDepth);
++
+             nCharCount--;
+ 
+             rIn >> nMask;
commit 7888341e169069a2a88a7db4b2d3bf63e4fefb6b
Author: Thorsten Behrens <tbehrens at novell.com>
Date:   Wed Feb 3 13:03:57 2010 +0100

    Avoid looping in draw/impress
    
    * patches/dev300/apply: added the patch
    * patches/dev300/sd-avoid-looping-fix.diff: fix a loop in the
      Atom ctor

diff --git a/patches/dev300/apply b/patches/dev300/apply
index c3c33bc..d3f459d 100644
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -3541,3 +3541,4 @@ framework-netbook.diff, rodo
 svx-sound.diff, n#515553, rodo
 sd-sound.diff, n#515553, rodo
 slideshow-sound.diff, n#515553, rodo
+sd-avoid-looping-fix.diff, thorsten
\ No newline at end of file
diff --git a/patches/dev300/sd-avoid-looping-fix.diff b/patches/dev300/sd-avoid-looping-fix.diff
new file mode 100644
index 0000000..f347d4c
--- /dev/null
+++ b/patches/dev300/sd-avoid-looping-fix.diff
@@ -0,0 +1,21 @@
+diff --git a/sd/source/filter/ppt/pptatom.cpp b/sd/source/filter/ppt/pptatom.cpp
+index d519898..3374b1c 100644
+--- sd/source/filter/ppt/pptatom.cpp
++++ sd/source/filter/ppt/pptatom.cpp
+@@ -52,7 +52,15 @@ Atom::Atom( const DffRecordHeader& rRecordHeader, SvStream& rStream )
+ 
+             Atom* pLastAtom = NULL;
+ 		
+-            while( (mrStream.GetError() == 0 ) && ( mrStream.Tell() < maRecordHeader.GetRecEndFilePos() ) )
++            // retrieve file size (to allow sanity checks) 
++            const sal_Size nStreamPos = mrStream.Tell();
++            mrStream.Seek( STREAM_SEEK_TO_END );
++            const sal_Size nStreamSize = mrStream.Tell();
++            mrStream.Seek( nStreamPos );
++
++            while( (mrStream.GetError() == 0 ) 
++                   && ( mrStream.Tell() < nStreamSize )
++                   && ( mrStream.Tell() < maRecordHeader.GetRecEndFilePos() ) )
+             {
+                 mrStream >> aChildHeader;
+ 


More information about the ooo-build-commit mailing list