diff options
author | Joshua Lock <josh@linux.intel.com> | 2011-08-05 16:12:12 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-08-09 15:19:59 +0100 |
commit | 138178f5d2e39065629f51abd577bd607ca570d0 (patch) | |
tree | d2caa1e4e75b6af3a31b75b47a48aab12a58540c /bitbake/lib/bb/ui/crumbs/tasklistmodel.py | |
parent | ecab5d610b2921ab50524aaf5b1ebc78d22dc0c0 (diff) | |
download | ast2050-yocto-poky-138178f5d2e39065629f51abd577bd607ca570d0.zip ast2050-yocto-poky-138178f5d2e39065629f51abd577bd607ca570d0.tar.gz |
bb/ui/crumbs/tasklistmodel: prevent hang when removing item
It's possible to trigger an infinite recursion when removing a package
where many of the dependencies share their dependencies. Prevent this by
keeping a list of removed item names and only removing the item when it's
not in the list.
Addresses [YOCTO #1319]
(Bitbake rev: 0ed58f28e869cceeefa930a3f1f46c5f3e9ffe21)
Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/ui/crumbs/tasklistmodel.py')
-rw-r--r-- | bitbake/lib/bb/ui/crumbs/tasklistmodel.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bitbake/lib/bb/ui/crumbs/tasklistmodel.py b/bitbake/lib/bb/ui/crumbs/tasklistmodel.py index 8fb5683..3e09757 100644 --- a/bitbake/lib/bb/ui/crumbs/tasklistmodel.py +++ b/bitbake/lib/bb/ui/crumbs/tasklistmodel.py @@ -315,6 +315,7 @@ class TaskListModel(gtk.ListStore): """ def mark(self, opath): usersel = {} + removed = [] it = self.get_iter_first() name = self[opath][self.COL_NAME] @@ -343,8 +344,9 @@ class TaskListModel(gtk.ListStore): usersel[iname] = self[path][self.COL_IMG] # FIXME: need to ensure partial name matching doesn't happen - if inc and deps.count(name): + if inc and deps.count(name) and name not in removed: # found a dependency, remove it + removed.append(name) self.mark(path) if inc and binb.count(name): |