summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-10-31 16:20:41 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-11-01 08:33:22 +0100
commit53bc3b618b5a97702a54d3aa4dbf7853d8980a5d (patch)
treec52f0524e05714e2eab23690e4de858e4a97fe09 /svx
parentcfdcb1bb0cf3a9fa2b342109cd581d3211e965bf (diff)
tdf#120997 Crash after Ctrl+Tab to traverse points of object, more fix
regression from commit b4fc996520b47a6212661a9de3a1c72ccfc379a4 loplugin:useuniqueptr in SdrHdlList Change-Id: I53e2adee9a1ad8ef73de5a9601238187a6002241 Reviewed-on: https://gerrit.libreoffice.org/62714 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/svdraw/svdhdl.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/svx/source/svdraw/svdhdl.cxx b/svx/source/svdraw/svdhdl.cxx
index 2c1ee22a064c..7dc05bc1a086 100644
--- a/svx/source/svdraw/svdhdl.cxx
+++ b/svx/source/svdraw/svdhdl.cxx
@@ -2063,10 +2063,9 @@ void SdrHdlList::TravelFocusHdl(bool bForward)
if(nOldHdlNum != nNewHdlNum)
{
mnFocusIndex = nNewHdlNum;
- SdrHdl* pNew = GetHdl(mnFocusIndex);
-
- if(pNew)
+ if (mnFocusIndex < GetHdlCount())
{
+ SdrHdl* pNew = GetHdl(mnFocusIndex);
pNew->Touch();
}
}