Code

specialize MaybeStorage for Rect, and start using reference maybes to
[inkscape.git] / src / sp-mask.cpp
index 9c8b0ba3251128f3e436b3dbbfd3249623c484c3..64ff38019d381b915b2f64cc952454be6110c450 100644 (file)
@@ -293,7 +293,8 @@ sp_mask_create (GSList *reprs, SPDocument *document, NR::Matrix const* applyTran
         }
     }
 
-    defsrepr->changeOrder(repr, defsrepr->lastChild()); // workaround for bug 989084
+    if (repr != defsrepr->lastChild())
+        defsrepr->changeOrder(repr, defsrepr->lastChild()); // workaround for bug 989084
     
     Inkscape::GC::release(repr);
     return mask_id;