svtools/source/misc/embedhlp.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
New commits: commit 61101d99c229da979626a8c3aa471a42acfe6295 Author: Miklos Vajna <vmik...@suse.cz> Date: Fri Apr 26 12:48:10 2013 +0200 EmbeddedObjectRef: guard against div by zero With this, if dc92bac5df72ecca123472a5e945b1864a17f457 fails, it won't crash, just the assertion will fail. Change-Id: I9830094088819cade7cf47d1f25d34bb6eb52ae6 diff --git a/svtools/source/misc/embedhlp.cxx b/svtools/source/misc/embedhlp.cxx index 318254e..7a3ce24 100644 --- a/svtools/source/misc/embedhlp.cxx +++ b/svtools/source/misc/embedhlp.cxx @@ -658,7 +658,7 @@ void EmbeddedObjectRef::DrawPaintReplacement( const Rectangle &rRect, const OUSt Bitmap aBmp( SvtResId( BMP_PLUGIN ) ); long nHeight = rRect.GetHeight() - pOut->GetTextHeight(); long nWidth = rRect.GetWidth(); - if( nHeight > 0 ) + if( nHeight > 0 && aBmp.GetSizePixel().Width() > 0 ) { aPt.Y() = nHeight; Point aP = rRect.TopLeft(); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits