[Libreoffice-commits] core.git: sw/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Fri Apr 10 16:06:52 UTC 2020


 sw/source/uibase/app/apphdl.cxx |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit b5a79a6e81086df034632716110124af6ee35109
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Fri Apr 10 16:21:33 2020 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Apr 10 18:06:16 2020 +0200

    null-deref of GetObjectShell
    
    Change-Id: Ie0c46635d9ad01a17b5d5028ed5f983fd8c5ee74
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92046
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sw/source/uibase/app/apphdl.cxx b/sw/source/uibase/app/apphdl.cxx
index 782445027c8c..e8bfe164cdca 100644
--- a/sw/source/uibase/app/apphdl.cxx
+++ b/sw/source/uibase/app/apphdl.cxx
@@ -158,7 +158,8 @@ void SwModule::StateOther(SfxItemSet &rSet)
             break;
             case FN_MAILMERGE_WIZARD:
             {
-                if (GetObjectShell()->isExportLocked())
+                SfxObjectShell* pObjectShell = GetObjectShell();
+                if (pObjectShell && pObjectShell->isExportLocked())
                     rSet.DisableItem(nWhich);
                 break;
             }


More information about the Libreoffice-commits mailing list