diff options
author | Slávek Banko <slavek.banko@axis.cz> | 2017-05-14 12:34:25 +0200 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2017-05-14 12:34:25 +0200 |
commit | eecb4690f18650b9139071301db63a24e6da0e39 (patch) | |
tree | 3e2c0a8fd5ea176d2faa20de5a518f6611cb6bec | |
parent | 27787971c73ffcecd7fc8c894e843affb4313f38 (diff) | |
download | tdepim-eecb4690f18650b9139071301db63a24e6da0e39.tar.gz tdepim-eecb4690f18650b9139071301db63a24e6da0e39.zip |
Fix crash on NULL pointer dereference
This resolves Bug 2773
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
-rw-r--r-- | korganizer/koeditorfreebusy.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/korganizer/koeditorfreebusy.cpp b/korganizer/koeditorfreebusy.cpp index 0ee9d4f8c..88c5414b3 100644 --- a/korganizer/koeditorfreebusy.cpp +++ b/korganizer/koeditorfreebusy.cpp @@ -850,10 +850,13 @@ void KOEditorFreeBusy::removeAttendee() void KOEditorFreeBusy::clearSelection() const { KDGanttViewItem *item = mGanttView->selectedItem(); - if ( item ) + if (item) { mGanttView->setSelected( item, false ); + } mGanttView->repaint(); - item->repaint(); + if (item) { + item->repaint(); + } } void KOEditorFreeBusy::setSelected( int index ) |