summaryrefslogtreecommitdiff
path: root/svtools/source/misc/embedhlp.cxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-03-31 16:54:34 +0100
committerCaolán McNamara <caolanm@redhat.com>2014-03-31 17:04:39 +0100
commit1e68d390229d1e446d1b77b395a70fa636cf5373 (patch)
tree6789cd3654921b709e3afb636b75cddef205381e /svtools/source/misc/embedhlp.cxx
parent058b5cac90051949388f136da74a515b212e7bac (diff)
coverity#982430 Division or modulo by zero
Change-Id: I9764d4e122c4dbab2349499f30c17842e432dadc
Diffstat (limited to 'svtools/source/misc/embedhlp.cxx')
-rw-r--r--svtools/source/misc/embedhlp.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/svtools/source/misc/embedhlp.cxx b/svtools/source/misc/embedhlp.cxx
index f9cf0478577e..55b6e9f13682 100644
--- a/svtools/source/misc/embedhlp.cxx
+++ b/svtools/source/misc/embedhlp.cxx
@@ -664,7 +664,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 && aBmp.GetSizePixel().Width() > 0 )
+ if(nHeight > 0 && nWidth > 0 && aBmp.GetSizePixel().Width() > 0)
{
aPt.Y() = nHeight;
Point aP = rRect.TopLeft();