Code

fix check for empty path for draw-context
authorjohanengelen <johanengelen@users.sourceforge.net>
Mon, 14 Jul 2008 19:39:19 +0000 (19:39 +0000)
committerjohanengelen <johanengelen@users.sourceforge.net>
Mon, 14 Jul 2008 19:39:19 +0000 (19:39 +0000)
src/draw-context.cpp

index 67c093b4187f877895f8781f709c0a72709449e3..6831654eab6f1bc687913b9aecc5ab9cb350f5df 100644 (file)
@@ -399,7 +399,7 @@ spdc_attach_selection(SPDrawContext *dc, Inkscape::Selection */*sel*/)
         for (GSList *l = dc->white_curves; l != NULL; l = l->next) {
             SPCurve *c;
             c = (SPCurve*)l->data;
-            g_return_if_fail( c->get_segment_count() > 1 );
+            g_return_if_fail( c->get_segment_count() > 0 );
             if ( !c->is_closed() ) {
                 SPDrawAnchor *a;
                 a = sp_draw_anchor_new(dc, c, TRUE, c->first_point());