0

Error in given code,

Invalid type for argument in function call.

 return ecrecover(operationHash, v, r, s);

And,

 function sendMultiSigToken (address toAddress, uint value, address tokenContractAddress, uint expireTime, bytes signature, uint sequenceId) public onlySigner{
    //verify the other signer
    var operationHash = keccak256("ERC20", toAddress, value, tokenContractAddress, expireTime, sequenceId);

  //error in verifyMultiSig's operationHash argument

    verifyMultiSig(toAddress, operationHash, signature, expireTime, sequenceId);
    EERC20Interface erc20instance = EERC20Interface(tokenContractAddress);
    if(!erc20instance.transfer(toAddress, value)){
        revert();
    }
}

How to solve these errors? I am using 0.4.10 version compiler.

2
  • What is the signature of verifyMultiSig? Your solc version is too old I'd encourage to use a newer version since v0.4.22 you have available abi.encodePacked solidity.readthedocs.io/en/v0.4.22/…, that you can use to convert any type to bytes.
    – Ismael
    Commented Jan 22, 2019 at 7:02
  • function verifyMultiSig(address toAddress, bytes32 operationHash, bytes signature, uint expireTime, uint sequenceId) private returns (address){ var otherSigner = recoverAddressFromSignature(operationHash, signature); }
    – Rudrika
    Commented Jan 22, 2019 at 7:32

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.