diff options
author | Martin Gysel <me@bearsh.org> | 2013-12-07 13:25:17 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2013-12-07 07:27:46 -0800 |
commit | d9ca999a17a45b5c993ed1a693c4c4e386393ec0 (patch) | |
tree | b0201eed17fb80e165f2d4d9297aac8d6d123de2 /qt-ui | |
parent | 26dab9b5ced06695e5a8130dac42948f0cbfb915 (diff) | |
download | subsurface-d9ca999a17a45b5c993ed1a693c4c4e386393ec0.tar.gz |
redraw profile (actually clean it) if no dive is selected
otherwise the previous selected dive is still visible in the profile
view. clicking on edit crashs subsurface: null pointer dereference in
editCurrentDive as it uses 'current_dive' which is null.
Signed-off-by: Martin Gysel <me@bearsh.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui')
-rw-r--r-- | qt-ui/mainwindow.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp index e4569911b..78868e683 100644 --- a/qt-ui/mainwindow.cpp +++ b/qt-ui/mainwindow.cpp @@ -86,8 +86,8 @@ void MainWindow::current_dive_changed(int divenr) if (divenr >= 0) { select_dive(divenr); ui.globe->centerOn(get_dive(selected_dive)); - redrawProfile(); } + redrawProfile(); ui.InfoWidget->updateDiveInfo(divenr); } |