summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: dd72119)
raw | patch | inline | side by side (parent: dd72119)
author | johanengelen <johanengelen@users.sourceforge.net> | |
Tue, 4 Dec 2007 23:53:07 +0000 (23:53 +0000) | ||
committer | johanengelen <johanengelen@users.sourceforge.net> | |
Tue, 4 Dec 2007 23:53:07 +0000 (23:53 +0000) |
src/sp-namedview.cpp | patch | blob | history |
diff --git a/src/sp-namedview.cpp b/src/sp-namedview.cpp
index 03cc4bdadea08fb80755622656dd0dbc137e23da..a26d1ce0e0fbb47e912f51ed87fc51c1576b9a32 100644 (file)
--- a/src/sp-namedview.cpp
+++ b/src/sp-namedview.cpp
@@ -513,9 +513,10 @@ static void sp_namedview_child_added(SPObject *object, Inkscape::XML::Node *chil
const gchar *id = child->attribute("id");
if (!strcmp(child->name(), "inkscape:grid")) {
sp_namedview_add_grid(nv, child, NULL);
- } else {
+ } else if (id) {
SPObject *no = object->document->getObjectById(id);
- g_assert(SP_IS_OBJECT(no));
+ if ( !SP_IS_OBJECT(no) )
+ return;
if (SP_IS_GUIDE(no)) {
SPGuide *g = (SPGuide *) no;