diff options
| author | Marc Jeanmougin <marc@jeanmougin.fr> | 2015-05-06 22:10:23 +0000 |
|---|---|---|
| committer | Marc Jeanmougin <marcjeanmougin@free.fr> | 2015-05-06 22:10:23 +0000 |
| commit | 8c3f982781088c386acb4105119b19d9c7160502 (patch) | |
| tree | 04ab0429ec45f15ace215ea79a4079c34553e4f1 /src/selection.cpp | |
| parent | UI. Fix for Bug #1450877 (GUI glitch in Object Properties) (diff) | |
| download | inkscape-8c3f982781088c386acb4105119b19d9c7160502.tar.gz inkscape-8c3f982781088c386acb4105119b19d9c7160502.zip | |
fix crash due to logic error in Selection::_removeObjectDescendants
(bzr r14117)
Diffstat (limited to 'src/selection.cpp')
| -rw-r--r-- | src/selection.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/selection.cpp b/src/selection.cpp index 53772c381..f728f3381 100644 --- a/src/selection.cpp +++ b/src/selection.cpp @@ -481,17 +481,21 @@ std::vector<Inkscape::SnapCandidatePoint> Selection::getSnapPoints(SnapPreferenc } void Selection::_removeObjectDescendants(SPObject *obj) { + std::vector<SPObject*> toremove; for ( std::list<SPObject*>::const_iterator iter=_objs.begin();iter!=_objs.end();iter++ ) { SPObject *sel_obj= *iter; SPObject *parent = sel_obj->parent; while (parent) { if ( parent == obj ) { - _remove(sel_obj); + toremove.push_back(sel_obj); break; } parent = parent->parent; } } + for ( std::vector<SPObject*>::const_iterator iter=toremove.begin();iter!=toremove.end();iter++ ) { + _remove(*iter); + } } void Selection::_removeObjectAncestors(SPObject *obj) { |
