diff options
| author | Johan B. C. Engelen <jbc.engelen@swissonline.ch> | 2014-03-24 19:41:57 +0000 |
|---|---|---|
| committer | Johan B. C. Engelen <j.b.c.engelen@alumnus.utwente.nl> | 2014-03-24 19:41:57 +0000 |
| commit | df81a0651a143161602542fa98558a96feda1f0f (patch) | |
| tree | dfed085908c1a8fa337324e9198cd905634ac112 /src/desktop.cpp | |
| parent | make it easier for people to build with -Werror on Windows (diff) | |
| download | inkscape-df81a0651a143161602542fa98558a96feda1f0f.tar.gz inkscape-df81a0651a143161602542fa98558a96feda1f0f.zip | |
fix potential calls on nullptr
(bzr r13194)
Diffstat (limited to 'src/desktop.cpp')
| -rw-r--r-- | src/desktop.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/desktop.cpp b/src/desktop.cpp index a02baeac8..6b5f696e0 100644 --- a/src/desktop.cpp +++ b/src/desktop.cpp @@ -1537,7 +1537,9 @@ SPDesktop::updateCanvasNow() void SPDesktop::setDocument (SPDocument *doc) { - if (this->doc() && doc) { + if (!doc) return; + + if (this->doc()) { namedview->hide(this); this->doc()->getRoot()->invoke_hide(dkey); } |
