Commit 9a46bf02 authored by Vincent Pelletier's avatar Vincent Pelletier

Use an intermediate set() to remove duplicate tids (as we request data from...

Use an intermediate set() to remove duplicate tids (as we request data from all storage nodes, the same tid wille be reported one time per node replicating it).


git-svn-id: https://svn.erp5.org/repos/neo/branches/prototype3@647 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent ac603ef1
......@@ -831,10 +831,11 @@ class Application(object):
continue
# Reorder tids
ordered_tids = []
extend = ordered_tids.extend
for tids in self.local_var.node_tids.itervalues():
extend(tids)
ordered_tids = set()
update = ordered_tids.update
for tid_list in self.local_var.node_tids.itervalues():
update(tid_list)
ordered_tids = list(ordered_tids)
# XXX do we need a special cmp function here ?
ordered_tids.sort(reverse=True)
logging.info("UndoLog, tids %s", ordered_tids)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment