Modexp fix example 1 (returned to early for ints of length 1)

This commit is contained in:
mratsim 2018-12-04 12:49:48 +01:00
parent 2521ff1950
commit 949c5a1dc6
2 changed files with 2 additions and 2 deletions

View File

@ -63,7 +63,7 @@ proc rangeToPaddedUint256*(x: seq[byte], first, last: int): Uint256 =
let lo = max(0, first)
let hi = min(x.high, last)
if not(lo < hi):
if not(lo <= hi):
return # 0
result = UInt256.fromBytesBE(