vcl/source/window/cursor.cxx |    3 +++
 1 file changed, 3 insertions(+)

New commits:
commit 27bb93877bf3d64cb033d42f3f5cf113ff15e25a
Author:     Henry Castro <[email protected]>
AuthorDate: Thu Jan 8 06:13:04 2026 -0400
Commit:     Caolán McNamara <[email protected]>
CommitDate: Wed Jan 14 12:36:46 2026 +0100

    vcl: fix nullptr dereference
    
    Backtrace 2787100 - kit startup of 25.04.9.0 854596da8b:
    coolforkit-ns(_ZN7SigUtil13dumpBacktraceEv+0x99)[0x562715e87576]
    coolforkit-ns(+0x2e147f)[0x562715e8747f]
    libc.so.6(+0x3c050)[0x7feacd05a050]
    libvcllo.so(+0x6585cdbw)[0x7feac20585cd]
    libvcllo.so(+0x656515)[0x7feac2056515]
    libvcllo.so(_ZN3vcl6Window24GetParentWithLOKNotifierEv+0x24)[0x7feac22c658e]
    libvcllo.so(+0x72697d)[0x7feac212697d]
    libvcllo.so(+0x727027)[0x7feac2127027]
    
    Signed-off-by: Henry Castro <[email protected]>
    Change-Id: I4c1057e3a5ba0e189727852adadd13a0de6819aa
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/196836
    Tested-by: Caolán McNamara <[email protected]>
    Reviewed-by: Caolán McNamara <[email protected]>
    Tested-by: Jenkins CollaboraOffice <[email protected]>

diff --git a/vcl/source/window/cursor.cxx b/vcl/source/window/cursor.cxx
index 535a0bde2a46..07fb3fbfc21b 100644
--- a/vcl/source/window/cursor.cxx
+++ b/vcl/source/window/cursor.cxx
@@ -274,6 +274,9 @@ tools::Rectangle calcualteCursorRect(Point const& 
rPosition, Size const rSize, v
 
 void vcl::Cursor::LOKNotify(vcl::Window* pWindow, const OUString& rAction)
 {
+    if (!pWindow)
+        return;
+
     VclPtr<vcl::Window> pParent = pWindow->GetParentWithLOKNotifier();
     if (!pParent)
         return;

Reply via email to