From: rwst Date: Mon, 13 Feb 2006 16:40:03 +0000 (+0000) Subject: no longer GC::release(NULL) with defect inx files, fixes #1358999 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=97153383e812cc9c0a0d87f944295edec69915d4;p=inkscape.git no longer GC::release(NULL) with defect inx files, fixes #1358999 --- diff --git a/src/extension/system.cpp b/src/extension/system.cpp index 34855cd4e..ccf168446 100644 --- a/src/extension/system.cpp +++ b/src/extension/system.cpp @@ -437,8 +437,9 @@ build_from_file(gchar const *filename) DTD in general for this stuff */ Inkscape::XML::Document *doc = sp_repr_read_file(filename, NULL); Extension *ext = build_from_reprdoc(doc, NULL); - Inkscape::GC::release(doc); - if (ext == NULL) + if (ext != NULL) + Inkscape::GC::release(doc); + else g_warning("Unable to create extension from definition file %s.\n", filename); return ext; }