Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Correctly detect+handle overflow in mp_get_int64
Handles the fact that for 64-bit 2's complement numbers the maximum positive value is 2**63 - 1, but the maximum negative value is 2**63. Uses the mp_get_long_long now available with the newer version of libtommath. Also, instead of counting the bits every time, only do it during the too-large-value error path.
- Loading branch information
1 parent
a844814
commit 84a730f
Showing
1 changed file
with
16 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters