mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-30 22:20:21 +00:00
Check if dive_site exists before accessing its name
... in copy dive to clipboad. Fixes #2109 Signed-off-by: Robert C. Helling <helling@atdotde.de>
This commit is contained in:
parent
f6ab84f13f
commit
b614a04330
1 changed files with 1 additions and 1 deletions
|
@ -496,7 +496,7 @@ void DiveComponentSelection::buttonClicked(QAbstractButton *button)
|
|||
QTextStream text;
|
||||
QString cliptext;
|
||||
text.setString(&cliptext);
|
||||
if (what->divesite)
|
||||
if (what->divesite && displayed_dive.dive_site)
|
||||
text << tr("Dive site: ") << displayed_dive.dive_site->name << "\n";
|
||||
if (what->divemaster)
|
||||
text << tr("Dive master: ") << displayed_dive.divemaster << "\n";
|
||||
|
|
Loading…
Reference in a new issue