http://hg.viff.dk/viff/rev/73b8246fbe5b
changeset: 1142:73b8246fbe5b
user: Marcel Keller <[email protected]>
date: Mon Feb 23 14:04:15 2009 +0100
summary: Use schedule_callback() instead of addCallback() for functions
relying on the program counter.
diffstat:
1 file changed, 6 insertions(+), 4 deletions(-)
viff/aes.py | 10 ++++++----
diffs (28 lines):
diff -r 4bacbff2e79f -r 73b8246fbe5b viff/aes.py
--- a/viff/aes.py Thu Feb 19 16:22:15 2009 +0100
+++ b/viff/aes.py Mon Feb 23 14:04:15 2009 +0100
@@ -136,8 +136,8 @@
if (c_opened == 0):
r_trial = self.runtime.prss_share_random(GF256)
c_trial = self.runtime.open((byte + b) * r_trial)
- c_trial.addCallback(get_masked_byte, r_trial,
- c, r, byte)
+ self.runtime.schedule_callback(c_trial, get_masked_byte,
+ r_trial, c, r, byte)
else:
r_related.addCallback(r.callback)
c.callback(~c_opened)
@@ -375,9 +375,11 @@
get_last(state).addCallback(progress, i, time.time())
if (i < self.rounds - 1):
- get_trigger(state).addCallback(round, state, i + 1)
+ self.runtime.schedule_callback(get_trigger(state),
+ round, state, i + 1)
else:
- get_trigger(state).addCallback(final_round, state)
+ self.runtime.schedule_callback(get_trigger(state),
+ final_round, state)
prep_progress(i, start_round)
_______________________________________________
viff-commits mailing list
[email protected]
http://lists.viff.dk/listinfo.cgi/viff-commits-viff.dk