summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTomasz Boczkowski <penginsbacon@gmail.com>2014-05-29 10:38:20 +0000
committerTomasz Boczkowski <penginsbacon@gmail.com>2014-05-29 10:38:20 +0000
commitf92d08e05a6e8af396e9afda669e3f25d06ee7bf (patch)
tree56877d24390a0825b517174d05e6895644ca68e5 /src
parentSPPattern c++-sification: class fields are private (diff)
downloadinkscape-f92d08e05a6e8af396e9afda669e3f25d06ee7bf.tar.gz
inkscape-f92d08e05a6e8af396e9afda669e3f25d06ee7bf.zip
fixed possible bug SPPattern::_get_children
(bzr r13341.6.24)
Diffstat (limited to 'src')
-rw-r--r--src/sp-pattern.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/sp-pattern.cpp b/src/sp-pattern.cpp
index c2835eadd..18eb78a27 100644
--- a/src/sp-pattern.cpp
+++ b/src/sp-pattern.cpp
@@ -214,10 +214,9 @@ void SPPattern::set(unsigned int key, const gchar* value) {
/* fixme: We need ::order_changed handler too (Lauris) */
void SPPattern::_get_children(std::list<SPObject*>& l) {
- SPPattern *pat = this;
- for (SPPattern *pat_i = pat; pat_i != NULL; pat_i = pat_i->ref ? pat_i->ref->getObject() : NULL) {
+ for (SPPattern *pat_i = this; pat_i != NULL; pat_i = pat_i->ref ? pat_i->ref->getObject() : NULL) {
if (pat_i->firstChild()) { // find the first one with children
- for (SPObject *child = pat->firstChild() ; child ; child = child->getNext() ) {
+ for (SPObject *child = pat_i->firstChild() ; child ; child = child->getNext() ) {
l.push_back(child);
}
break; // do not go further up the chain if children are found