summaryrefslogtreecommitdiffstats
path: root/src/sp-item.cpp
diff options
context:
space:
mode:
authorJohan B. C. Engelen <jbc.engelen@swissonline.ch>2013-10-28 19:41:27 +0000
committerJohan B. C. Engelen <j.b.c.engelen@alumnus.utwente.nl>2013-10-28 19:41:27 +0000
commit243e788771fab25a6015d8c136307f0a9f9b130c (patch)
tree5a1c50d8545a0ace37c6fdfa6df5e18924bf6928 /src/sp-item.cpp
parentunit display: fix typo (diff)
downloadinkscape-243e788771fab25a6015d8c136307f0a9f9b130c.tar.gz
inkscape-243e788771fab25a6015d8c136307f0a9f9b130c.zip
fix crash
Fixed bugs: - https://launchpad.net/bugs/854617 (bzr r12742)
Diffstat (limited to 'src/sp-item.cpp')
-rw-r--r--src/sp-item.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/sp-item.cpp b/src/sp-item.cpp
index 55ff60aeb..c6daa853c 100644
--- a/src/sp-item.cpp
+++ b/src/sp-item.cpp
@@ -1374,11 +1374,12 @@ void SPItem::doWriteTransform(Inkscape::XML::Node *repr, Geom::Affine const &tra
if ( // run the object's set_transform (i.e. embed transform) only if:
!preserve && // user did not chose to preserve all transforms
- !clip_ref->getObject() && // the object does not have a clippath
- !mask_ref->getObject() && // the object does not have a mask
+ (!clip_ref || !clip_ref->getObject()) && // the object does not have a clippath
+ (!mask_ref || !mask_ref->getObject()) && // the object does not have a mask
!(!transform.isTranslation() && style && style->getFilter()) // the object does not have a filter, or the transform is translation (which is supposed to not affect filters)
- ) {
- transform_attr = this->set_transform(transform);
+ )
+ {
+ transform_attr = this->set_transform(transform);
if (freeze_stroke_width) {
freeze_stroke_width_recursive(false);