summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-12-20 10:46:20 +0000
committerCarl Hetherington <cth@carlh.net>2016-12-20 10:46:20 +0000
commitf8e6fdee828647bc5a6a1cc7627052a072a37dc6 (patch)
tree2c8cdcff04b061a210e8bddcb57f62e67fe82fb2 /src
parent2a17b002ab6a5fc52e0c40bea691cdb506ca59be (diff)
Fix crash introduced by previous commit.
Diffstat (limited to 'src')
-rw-r--r--src/wx/content_sub_panel.cc10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/wx/content_sub_panel.cc b/src/wx/content_sub_panel.cc
index e9d082701..674b30369 100644
--- a/src/wx/content_sub_panel.cc
+++ b/src/wx/content_sub_panel.cc
@@ -68,10 +68,12 @@ ContentSubPanel::setup_refer_button (wxCheckBox* button, shared_ptr<DCPContent>
}
/* XXX: more debugging */
- if (!s.IsEmpty()) {
- dcp->film()->log()->log (String::compose ("setting tooltip to %1", wx_to_std (s)), LogEntry::TYPE_GENERAL);
- } else {
- dcp->film()->log()->log ("clearing tooltip", LogEntry::TYPE_GENERAL);
+ if (dcp) {
+ if (!s.IsEmpty()) {
+ dcp->film()->log()->log (String::compose ("setting tooltip to %1", wx_to_std (s)), LogEntry::TYPE_GENERAL);
+ } else {
+ dcp->film()->log()->log ("clearing tooltip", LogEntry::TYPE_GENERAL);
+ }
}
button->SetToolTip (s);