mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Do not keep the gas stipend if sending non-zero value
This commit is contained in:
parent
a36e2ce0cb
commit
c674155e58
@ -627,7 +627,7 @@ bool ExpressionCompiler::visit(FunctionCall const& _functionCall)
|
|||||||
*arguments.front()->annotation().type,
|
*arguments.front()->annotation().type,
|
||||||
*function.parameterTypes().front(), true
|
*function.parameterTypes().front(), true
|
||||||
);
|
);
|
||||||
if (function.location() != Location::Transfer)
|
if (!function.gasSet())
|
||||||
{
|
{
|
||||||
// gas <- gas * !value
|
// gas <- gas * !value
|
||||||
m_context << Instruction::SWAP1 << Instruction::DUP2;
|
m_context << Instruction::SWAP1 << Instruction::DUP2;
|
||||||
|
Loading…
Reference in New Issue
Block a user