mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Update compilation tests.
This commit is contained in:
parent
82f512a7d4
commit
0011f8aef9
@ -226,13 +226,11 @@ contract MultiSigWallet {
|
|||||||
{
|
{
|
||||||
if (isConfirmed(transactionId)) {
|
if (isConfirmed(transactionId)) {
|
||||||
Transaction storage tx = transactions[transactionId];
|
Transaction storage tx = transactions[transactionId];
|
||||||
tx.executed = true;
|
(tx.executed,) = tx.destination.call.value(tx.value)(tx.data);
|
||||||
if (tx.destination.call.value(tx.value)(tx.data))
|
if (tx.executed)
|
||||||
emit Execution(transactionId);
|
emit Execution(transactionId);
|
||||||
else {
|
else
|
||||||
emit ExecutionFailure(transactionId);
|
emit ExecutionFailure(transactionId);
|
||||||
tx.executed = false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -45,14 +45,13 @@ contract MultiSigWalletWithDailyLimit is MultiSigWallet {
|
|||||||
Transaction storage tx = transactions[transactionId];
|
Transaction storage tx = transactions[transactionId];
|
||||||
bool confirmed = isConfirmed(transactionId);
|
bool confirmed = isConfirmed(transactionId);
|
||||||
if (confirmed || tx.data.length == 0 && isUnderLimit(tx.value)) {
|
if (confirmed || tx.data.length == 0 && isUnderLimit(tx.value)) {
|
||||||
tx.executed = true;
|
|
||||||
if (!confirmed)
|
if (!confirmed)
|
||||||
spentToday += tx.value;
|
spentToday += tx.value;
|
||||||
if (tx.destination.call.value(tx.value)(tx.data))
|
(tx.executed,) = tx.destination.call.value(tx.value)(tx.data);
|
||||||
|
if (tx.executed)
|
||||||
emit Execution(transactionId);
|
emit Execution(transactionId);
|
||||||
else {
|
else {
|
||||||
emit ExecutionFailure(transactionId);
|
emit ExecutionFailure(transactionId);
|
||||||
tx.executed = false;
|
|
||||||
if (!confirmed)
|
if (!confirmed)
|
||||||
spentToday -= tx.value;
|
spentToday -= tx.value;
|
||||||
}
|
}
|
||||||
|
@ -360,8 +360,8 @@ contract MilestoneTracker {
|
|||||||
// Recheck again to not pay twice
|
// Recheck again to not pay twice
|
||||||
if (milestone.status == MilestoneStatus.AuthorizedForPayment) revert();
|
if (milestone.status == MilestoneStatus.AuthorizedForPayment) revert();
|
||||||
milestone.status = MilestoneStatus.AuthorizedForPayment;
|
milestone.status = MilestoneStatus.AuthorizedForPayment;
|
||||||
if (!milestone.paymentSource.call.value(0)(milestone.payData))
|
(bool success,) = milestone.paymentSource.call.value(0)(milestone.payData);
|
||||||
revert();
|
require(success);
|
||||||
emit ProposalStatusChanged(_idMilestone, milestone.status);
|
emit ProposalStatusChanged(_idMilestone, milestone.status);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -60,9 +60,8 @@ contract MultisigWallet is Multisig, Shareable, DayLimit {
|
|||||||
if (underLimit(_value)) {
|
if (underLimit(_value)) {
|
||||||
emit SingleTransact(msg.sender, _value, _to, _data);
|
emit SingleTransact(msg.sender, _value, _to, _data);
|
||||||
// yes - just execute the call.
|
// yes - just execute the call.
|
||||||
if (!_to.call.value(_value)(_data)) {
|
(bool success,) = _to.call.value(_value)(_data);
|
||||||
revert();
|
require(success);
|
||||||
}
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
// determine our operation hash.
|
// determine our operation hash.
|
||||||
@ -82,9 +81,8 @@ contract MultisigWallet is Multisig, Shareable, DayLimit {
|
|||||||
*/
|
*/
|
||||||
function confirm(bytes32 _h) onlymanyowners(_h) public returns (bool) {
|
function confirm(bytes32 _h) onlymanyowners(_h) public returns (bool) {
|
||||||
if (txs[_h].to != address(0)) {
|
if (txs[_h].to != address(0)) {
|
||||||
if (!txs[_h].to.call.value(txs[_h].value)(txs[_h].data)) {
|
(bool success,) = txs[_h].to.call.value(txs[_h].value)(txs[_h].data);
|
||||||
revert();
|
require(success);
|
||||||
}
|
|
||||||
emit MultiTransact(msg.sender, _h, txs[_h].value, txs[_h].to, txs[_h].data);
|
emit MultiTransact(msg.sender, _h, txs[_h].value, txs[_h].to, txs[_h].data);
|
||||||
delete txs[_h];
|
delete txs[_h];
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user