summaryrefslogtreecommitdiffstats
path: root/src/conn-avoid-ref.cpp
diff options
context:
space:
mode:
authorMichael Wybrow <michael.wybrow@monash.edu>2010-08-13 08:39:11 +0000
committerMichael Wybrow <mjwybrow@users.sf.net>2010-08-13 08:39:11 +0000
commita705cc22a15beab3ba8c25b67d70a9fa55607893 (patch)
treea94293a31cda23e6cfc50088beca4e6972a99341 /src/conn-avoid-ref.cpp
parentFixes bug #478597 where the connector context crash due to asserting that (diff)
downloadinkscape-a705cc22a15beab3ba8c25b67d70a9fa55607893.tar.gz
inkscape-a705cc22a15beab3ba8c25b67d70a9fa55607893.zip
Fixes bug #590047: assertion crash in libavoid when marking shapes as not
being avoided by the connector context. Fixed bugs: - https://launchpad.net/bugs/590047 (bzr r9708.1.1)
Diffstat (limited to 'src/conn-avoid-ref.cpp')
-rw-r--r--src/conn-avoid-ref.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/conn-avoid-ref.cpp b/src/conn-avoid-ref.cpp
index 88c84a84c..a918f8745 100644
--- a/src/conn-avoid-ref.cpp
+++ b/src/conn-avoid-ref.cpp
@@ -63,8 +63,8 @@ SPAvoidRef::~SPAvoidRef()
const bool routerInstanceExists = (item->document->router != NULL);
if (shapeRef && routerInstanceExists) {
- Router *router = shapeRef->router();
- router->removeShape(shapeRef);
+ // Deleting the shapeRef will remove it completely from
+ // an existing Router instance.
delete shapeRef;
}
shapeRef = NULL;
@@ -329,7 +329,8 @@ void SPAvoidRef::handleSettingChange(void)
{
g_assert(shapeRef);
- router->removeShape(shapeRef);
+ // Deleting the shapeRef will remove it completely from
+ // an existing Router instance.
delete shapeRef;
shapeRef = NULL;
}