[Libreoffice-commits] .: vcl/win

Jesús Corrius jcorrius at kemper.freedesktop.org
Mon Jun 20 13:22:37 PDT 2011


 vcl/win/source/window/salframe.cxx |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit 64204828408f5f2413d435139289df9032ac1951
Author: Jesús Corrius <jesus at softcatala.org>
Date:   Mon Jun 20 22:21:13 2011 +0200

    Avoid possible null pointer dereference

diff --git a/vcl/win/source/window/salframe.cxx b/vcl/win/source/window/salframe.cxx
index 9f72bb6..7b8239f 100644
--- a/vcl/win/source/window/salframe.cxx
+++ b/vcl/win/source/window/salframe.cxx
@@ -5239,7 +5239,11 @@ static void ImplHandleInputLangChange( HWND hWnd, WPARAM, LPARAM lParam )
 
     // Feststellen, ob wir IME unterstuetzen
     WinSalFrame* pFrame = GetWindowPtr( hWnd );
-    if ( pFrame && pFrame->mbIME && pFrame->mhDefIMEContext )
+
+    if ( !pFrame )
+        return;
+
+    if ( pFrame->mbIME && pFrame->mhDefIMEContext )
     {
         HKL     hKL = (HKL)lParam;
         UINT    nImeProps = ImmGetProperty( hKL, IGP_PROPERTY );


More information about the Libreoffice-commits mailing list