From 40214cd04823c5923740032284c5035b8cd27f6c Mon Sep 17 00:00:00 2001 From: buliabyak Date: Wed, 24 Jan 2007 18:33:43 +0000 Subject: [PATCH] fix crash when switching away from node tool while redrawing after a handle move; the end_forced_full_redraws in the handle_ungrabbed may become invalid because the nodepath is destroyed while in screen update triggered by update_repr, and it is redundant anyway because update_repr does its own end_forced_full_redraws --- src/nodepath.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/nodepath.cpp b/src/nodepath.cpp index a224f81a5..69827bd84 100644 --- a/src/nodepath.cpp +++ b/src/nodepath.cpp @@ -3322,7 +3322,6 @@ static void node_handle_ungrabbed(SPKnot *knot, guint state, gpointer data) } sp_nodepath_update_repr(n->subpath->nodepath, _("Move node handle")); - sp_canvas_end_forced_full_redraws(n->subpath->nodepath->desktop->canvas); } /** @@ -4038,6 +4037,7 @@ static void sp_nodepath_node_destroy(Inkscape::NodePath::Node *node) g_signal_handlers_disconnect_by_func(G_OBJECT(node->p.knot), (gpointer) G_CALLBACK(node_handle_moved), node); g_signal_handlers_disconnect_by_func(G_OBJECT(node->p.knot), (gpointer) G_CALLBACK(node_handle_event), node); g_object_unref(G_OBJECT(node->p.knot)); + node->p.knot = NULL; } if (node->n.knot) { @@ -4048,6 +4048,7 @@ static void sp_nodepath_node_destroy(Inkscape::NodePath::Node *node) g_signal_handlers_disconnect_by_func(G_OBJECT(node->n.knot), (gpointer) G_CALLBACK(node_handle_moved), node); g_signal_handlers_disconnect_by_func(G_OBJECT(node->n.knot), (gpointer) G_CALLBACK(node_handle_event), node); g_object_unref(G_OBJECT(node->n.knot)); + node->n.knot = NULL; } if (node->p.line) -- 2.39.5