Skip to content

Commit

Permalink
Fix conversion order
Browse files Browse the repository at this point in the history
  • Loading branch information
practicalswift authored and rustyrussell committed Mar 16, 2018
1 parent b8846da commit c85c2fc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bitcoin/signature.c
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ static bool IsValidSignatureEncoding(const unsigned char sig[], size_t len)

// Verify that the length of the signature matches the sum of the length
// of the elements.
if ((size_t)(lenR + lenS + 7) != len) return false;
if ((size_t)lenR + (size_t)lenS + 7 != len) return false;

// Check whether the R element is an integer.
if (sig[2] != 0x02) return false;
Expand Down

0 comments on commit c85c2fc

Please sign in to comment.