diff options
author | Remco Bloemen <remco@wicked.ventures> | 2018-02-24 06:52:12 +0800 |
---|---|---|
committer | Amir Bandeali <abandeali1@gmail.com> | 2018-04-21 04:56:16 +0800 |
commit | 83a63f64b1a2bd053ded0be6a941401fdc305ab3 (patch) | |
tree | 0f027ff90d6fc0e475355821c28c4d51508eeb1d /packages/contracts/src | |
parent | 8f7e67367adea778812bcb3bedebb8c36ef4198d (diff) | |
download | dexon-sol-tools-83a63f64b1a2bd053ded0be6a941401fdc305ab3.tar dexon-sol-tools-83a63f64b1a2bd053ded0be6a941401fdc305ab3.tar.gz dexon-sol-tools-83a63f64b1a2bd053ded0be6a941401fdc305ab3.tar.bz2 dexon-sol-tools-83a63f64b1a2bd053ded0be6a941401fdc305ab3.tar.lz dexon-sol-tools-83a63f64b1a2bd053ded0be6a941401fdc305ab3.tar.xz dexon-sol-tools-83a63f64b1a2bd053ded0be6a941401fdc305ab3.tar.zst dexon-sol-tools-83a63f64b1a2bd053ded0be6a941401fdc305ab3.zip |
Spelling fixes
Diffstat (limited to 'packages/contracts/src')
-rw-r--r-- | packages/contracts/src/contracts/current/protocol/Exchange/MixinSignatureValidator.sol | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/packages/contracts/src/contracts/current/protocol/Exchange/MixinSignatureValidator.sol b/packages/contracts/src/contracts/current/protocol/Exchange/MixinSignatureValidator.sol index 8555efa85..91e788763 100644 --- a/packages/contracts/src/contracts/current/protocol/Exchange/MixinSignatureValidator.sol +++ b/packages/contracts/src/contracts/current/protocol/Exchange/MixinSignatureValidator.sol @@ -50,9 +50,10 @@ contract MixinSignatureValidator is uint8 v; bytes32 r; bytes32 s; + address recovered; // Always illegal signature - // This is always an implicit option, since a signer can create a + // This is always an implicit option since a signer can create a // signature array with invalid type or length. We may as well make // it an explicit option. This aids testing and analysis. It is // also the initialization value for the enum type. @@ -60,8 +61,8 @@ contract MixinSignatureValidator is revert(); // Always invalid signature - // Like Illegal, this is always implicitely available and therefore - // offered dxplicitely. It can be implicitely creates by providing + // Like Illegal, this is always implicitly available and therefore + // offered explicitly. It can be implicitly created by providing // a validly formatted but incorrect signature. } else if (signatureType == SignatureType.Invalid) { require(signature.length == 1); @@ -71,9 +72,9 @@ contract MixinSignatureValidator is // Implicitly signed by caller // The signer has initiated the call. In the case of non-contract // accounts it means the transaction itself was signed. - // Example: lets say for a particular operation three signatures + // Example: let's say for a particular operation three signatures // A, B are required. To submit the transaction, A and B can give - // a signatue to C, who can then submit the transaction using + // a signature to C, who can then submit the transaction using // `Caller` for his own signature. Or A and C can sign and B can // submit using `Caller`. Having `Caller` allows this flexibility. } else if (signatureType == SignatureType.Caller) { @@ -100,8 +101,8 @@ contract MixinSignatureValidator is } else if (signatureType == SignatureType.EIP712) { v = uint8(signature[1]); r = get32(signature, 2); - s = get32(signature, 35); - address recovered = ecrecover(hash, v, r, s); + s = get32(signature, 34); + recovered = ecrecover(hash, v, r, s); isValid = signer == recovered; return isValid; |