/rev/613aa672ba5e
changeset: 1325:613aa672ba5e
user:      Marcel Keller <[email protected]>
date:      Thu Oct 22 19:38:31 2009 +0200
summary:   shamir: Optimized by using reflected argument operators.

diffstat:

 viff/shamir.py |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 382f0eb42dca -r 613aa672ba5e viff/shamir.py
--- a/viff/shamir.py    Thu Oct 22 19:38:16 2009 +0200
+++ b/viff/shamir.py    Thu Oct 22 19:38:31 2009 +0200
@@ -79,7 +79,7 @@
         cur_share = coef[threshold]
         # Go backwards from threshold-1 down to 0
         for j in range(threshold-1, -1, -1):
-            cur_share = coef[j] + cur_point * cur_share
+            cur_share = coef[j] + cur_share * cur_point
 
         shares.append((cur_point, cur_share))
 
_______________________________________________
viff-commits mailing list
[email protected]
http://lists.viff.dk/listinfo.cgi/viff-commits-viff.dk

Reply via email to