Fix an issue in suicide module

pull/757/head
Bernhard Mueller 6 years ago
parent c9ff1010ea
commit e2a5308016
  1. 7
      mythril/analysis/modules/suicide.py

@ -24,11 +24,14 @@ def _analyze_state(state):
try: try:
try: try:
transaction_sequence = solver.get_transaction_sequence( transaction_sequence = solver.get_transaction_sequence(
state, node.constraints state,
node.constraints + [to == 0xDEADBEEFDEADBEEFDEADBEEFDEADBEEFDEADBEEF],
) )
description = "Anyone can kill this contract and withdraw its balance to their own account." description = "Anyone can kill this contract and withdraw its balance to their own account."
except UnsatError: except UnsatError:
transaction_sequence = solver.get_transaction_sequence(state, constraints) transaction_sequence = solver.get_transaction_sequence(
state, node.constraints
)
description = ( description = (
"The contract can be killed by anyone. Don't accidentally kill it." "The contract can be killed by anyone. Don't accidentally kill it."
) )

Loading…
Cancel
Save