Skip to content

Commit

Permalink
Correct bug in bn submodule.
Browse files Browse the repository at this point in the history
  • Loading branch information
Laurent Girod committed Apr 7, 2020
1 parent 923c97f commit de42d70
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion petrelic/bn.py
Original file line number Diff line number Diff line change
Expand Up @@ -610,7 +610,7 @@ def __pow__(self, n, modulo=None):

if _C.bn_sign(n.bn) == _C.CONST_RLC_NEG:
base = base.mod_inverse(modulo)
_C.bn_neg(n.bn)
_C.bn_neg(n.bn, n.bn)

if _C.bn_is_zero(n.bn) == 1:
return Bn(1)
Expand Down

0 comments on commit de42d70

Please sign in to comment.