From 4e07c7e279b21c4ae93b832a65e221e2dab5391d Mon Sep 17 00:00:00 2001 From: Tomaž Vajngerl Date: Mon, 11 Apr 2016 16:37:25 +0900 Subject: coverity#1358428 fix "Null pointer dereferences" Change-Id: I629ff54ea721f4d9626258690767088b1abfb0c6 --- vcl/opengl/texture.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'vcl') diff --git a/vcl/opengl/texture.cxx b/vcl/opengl/texture.cxx index b3a36263271b..38ff8f7bd3fb 100644 --- a/vcl/opengl/texture.cxx +++ b/vcl/opengl/texture.cxx @@ -398,11 +398,11 @@ void OpenGLTexture::FillCoords(std::vector& aCoord, const GLfloat y1 = 0.0f; GLfloat y2 = 0.0f; - double fTextureWidth(mpImpl->mnWidth); - double fTextureHeight(mpImpl->mnHeight); - if (mpImpl) { + double fTextureWidth(mpImpl->mnWidth); + double fTextureHeight(mpImpl->mnHeight); + x1 = (maRect.Left() + rPosAry.mnSrcX) / fTextureWidth; x2 = (maRect.Left() + rPosAry.mnSrcX + rPosAry.mnSrcWidth) / fTextureWidth; -- cgit