diff options
author | Michael Meeks <michael.meeks@collabora.com> | 2018-12-12 09:18:09 +0000 |
---|---|---|
committer | Xisco Faulí <xiscofauli@libreoffice.org> | 2018-12-12 18:23:28 +0100 |
commit | 27995e638e1582b443befa93bc5dfd5970a38ef2 (patch) | |
tree | 7c70d1ec4f302a361e990f15599529075ed4bcbe /dbaccess | |
parent | 89c888b48eca24e25ffe8895542cf7ac9b731187 (diff) |
tdf#122020 - avoid nullptr deref.
Change-Id: Iaa63a90841523061490d207ba5403de26d5c0025
Reviewed-on: https://gerrit.libreoffice.org/65005
Tested-by: Jenkins
Reviewed-by: Xisco Faulí <xiscofauli@libreoffice.org>
Diffstat (limited to 'dbaccess')
-rw-r--r-- | dbaccess/source/ui/control/dbtreelistbox.cxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/dbaccess/source/ui/control/dbtreelistbox.cxx b/dbaccess/source/ui/control/dbtreelistbox.cxx index 1925a2247c8a..03b87a1b2517 100644 --- a/dbaccess/source/ui/control/dbtreelistbox.cxx +++ b/dbaccess/source/ui/control/dbtreelistbox.cxx @@ -183,7 +183,9 @@ IMPL_LINK(DBTreeListBox, OnResetEntry, void*, p, void) // set the flag which allows if the entry can be expanded pEntry->SetFlags( (pEntry->GetFlags() & ~SvTLEntryFlags(SvTLEntryFlags::NO_NODEBMP | SvTLEntryFlags::HAD_CHILDREN)) | SvTLEntryFlags::CHILDREN_ON_DEMAND ); // redraw the entry - GetModel()->InvalidateEntry( pEntry ); + SvTreeList* myModel = GetModel(); + if (myModel) + myModel->InvalidateEntry( pEntry ); } void DBTreeListBox::ModelHasEntryInvalidated( SvTreeListEntry* _pEntry ) |