Unverified Commit b5c4ea56 authored by Péter Szilágyi's avatar Péter Szilágyi Committed by GitHub

Merge pull request #20540 from holiman/verbose_panic

core/state: add more verbosity to panic
parents b211742e fc392395
......@@ -204,7 +204,7 @@ func (s *StateDB) AddRefund(gas uint64) {
func (s *StateDB) SubRefund(gas uint64) {
s.journal.append(refundChange{prev: s.refund})
if gas > s.refund {
panic("Refund counter below zero")
panic(fmt.Sprintf("Refund counter below zero (gas: %d > refund: %d)", gas, s.refund))
}
s.refund -= gas
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment