mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Do not try to display checksummed address for too-short/long address literals
This commit is contained in:
1 parent
6ebc094474
commit
1d5dd909b4
3 files changed
+5
-3
No files matched your search
@@ -587,5 +587,7 @@ bool Literal::passesAddressChecksum() const
|
||||
std::string Literal::getChecksummedAddress() const
|
||||
{
|
||||
solAssert(isHexNumber(), "Expected hex number");
|
||||
if (value().length != 42)
|
||||
return string();
|
||||
return dev::getChecksummedAddress(value());
|
||||
}
|
||||
Reference in new issue
Block a user