Fix destinationLen computing

This commit is contained in:
pscott
2021-04-22 11:40:12 +02:00
parent 4c067f2a43
commit d1f5cd0286

View File

@@ -47,7 +47,8 @@ static int check_deposit_contract(ethPluginInitContract_t *msg) {
&global_sha3,
chainConfig);
uint8_t destinationLen = strlen(destinationAddress);
uint8_t destinationLen = strlen(destinationAddress) + 1; // Adding one to account for \0.
// Ensure address is in lowercase, to match DEPOSIT_CONTRACT_ADDRESS' case.
to_lowercase(destinationAddress, destinationLen);