diff options
author | Caolán McNamara <caolan.mcnamara@collabora.com> | 2023-09-29 09:15:00 +0100 |
---|---|---|
committer | Caolán McNamara <caolan.mcnamara@collabora.com> | 2023-09-29 14:14:18 +0200 |
commit | ace3634dacfc177a9ad92db8b2d0b596891c1814 (patch) | |
tree | f84173db63ebd7c0cb542a58ebda5520cedf1562 /sfx2/source/view/lokcharthelper.cxx | |
parent | 86160b081b316532ed83cb9365714a06b1c13326 (diff) |
cid#1546831 Dereference after null check
Change-Id: I8c51dd1b312f02534f138b4fe6752ad26f5ac96c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157399
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Diffstat (limited to 'sfx2/source/view/lokcharthelper.cxx')
-rw-r--r-- | sfx2/source/view/lokcharthelper.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sfx2/source/view/lokcharthelper.cxx b/sfx2/source/view/lokcharthelper.cxx index c7941e6aa2ac..f8e8ec47ea4e 100644 --- a/sfx2/source/view/lokcharthelper.cxx +++ b/sfx2/source/view/lokcharthelper.cxx @@ -175,7 +175,7 @@ bool LokChartHelper::HitAny(const Point& aPos, bool bNegativeX) SfxViewShell* pViewShell = SfxViewShell::GetFirst(); while (pViewShell) { - if (pViewShell->GetDocId() == pCurView->GetDocId() && pViewShell->getPart() == nPartForCurView) + if (pCurView && pViewShell->GetDocId() == pCurView->GetDocId() && pViewShell->getPart() == nPartForCurView) { LokChartHelper aChartHelper(pViewShell, bNegativeX); if (aChartHelper.Hit(aPos)) |