summaryrefslogtreecommitdiffstats
path: root/src/splivarot.cpp
diff options
context:
space:
mode:
authorJohan B. C. Engelen <jbc.engelen@swissonline.ch>2011-05-01 14:27:28 +0000
committerJohan Engelen <goejendaagh@zonnet.nl>2011-05-01 14:27:28 +0000
commit7f81932011c4ad87db74d62a2843949f4a5a3ffe (patch)
tree6177fdcf66834758843b4e3211a9f8819508d659 /src/splivarot.cpp
parentGerman translation update (diff)
downloadinkscape-7f81932011c4ad87db74d62a2843949f4a5a3ffe.tar.gz
inkscape-7f81932011c4ad87db74d62a2843949f4a5a3ffe.zip
Fix crashes on empty marker definitions.
Fixed bugs: - https://launchpad.net/bugs/774834 (bzr r10195)
Diffstat (limited to 'src/splivarot.cpp')
-rw-r--r--src/splivarot.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/splivarot.cpp b/src/splivarot.cpp
index ac2acf330..5ff394782 100644
--- a/src/splivarot.cpp
+++ b/src/splivarot.cpp
@@ -607,6 +607,9 @@ void sp_selected_path_outline_add_marker( SPObject *marker_object, Geom::Affine
{
SPMarker* marker = SP_MARKER (marker_object);
SPItem* marker_item = sp_item_first_item_child(marker_object);
+ if (!marker_item) {
+ return;
+ }
Geom::Affine tr(marker_transform);
@@ -665,7 +668,9 @@ void item_outline_add_marker( SPObject const *marker_object, Geom::Affine marker
tr = marker->c2p * tr;
SPItem const * marker_item = sp_item_first_item_child(marker_object); // why only consider the first item? can a marker only consist of a single item (that may be a group)?
- item_outline_add_marker_child(marker_item, tr, pathv_in);
+ if (marker_item) {
+ item_outline_add_marker_child(marker_item, tr, pathv_in);
+ }
}
/**