Contracts programmed to receive ether should implement a way to withdraw it, i.e., call <code>transfer</code> (recommended), <code>send</code>, or <code>call.value</code> at least once.
if (x.balance < 10 && myAddress.balance >= 10) x.send(10);
}
}
contract GoodMarketPlace3 {
uint a;
function deposit(address w){
w.transfer(9);
}
function deposit1() payable {}
function foo() {a=0;}
}
// <yes> <report> SOLIDITY_LOCKED_MONEY 30281d
contract BadMarketPlace1 {
function deposit() payable {}
function foo() {}
}
contract GoodMarketPlace6 {
address s;
function deposit() payable {}
function foo(uint amount) payable {
s.call.value(amount)();
}
}
// <yes> <report> SOLIDITY_LOCKED_MONEY 30281d
contract BadMarketPlace2 {
function() payable {}
}
// <yes> <report> SOLIDITY_LOCKED_MONEY 30281d
contract BadMarketPlace3 {
function() payable {}
}
contract GoodMarketPlace9 {
function() payable external{}
function foo(address a, bytes calldata data) payable external {
a.delegatecall(data);
}
}
library BadMarketPlaceLibrary {
function foo() {}
}
```
### Abstract Syntax Tree
[Click Here](https://astexplorer.net/#/gist/68f4866e7f27e43b61182f734ef3d8d3/69d533bc968d5e66542ebc214ff3845c7066737c) to view the AST for the above code. Code generated from AST Explorer using _solidity-parser-antlr-0.4.11_