aboutsummaryrefslogtreecommitdiffstats
path: root/ethchain/state_manager.go
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-07-04 21:32:10 +0800
committerobscuren <geffobscura@gmail.com>2014-07-04 21:32:10 +0800
commit90eb4f1939f7b0389d5784b889cc0e5d2b3451f7 (patch)
treec812cf882cb5a22ea7ffd4a061be2ac286dcfa58 /ethchain/state_manager.go
parent23b5b5fa36530eb82543d7d877f8e9e1900232cf (diff)
downloaddexon-90eb4f1939f7b0389d5784b889cc0e5d2b3451f7.tar
dexon-90eb4f1939f7b0389d5784b889cc0e5d2b3451f7.tar.gz
dexon-90eb4f1939f7b0389d5784b889cc0e5d2b3451f7.tar.bz2
dexon-90eb4f1939f7b0389d5784b889cc0e5d2b3451f7.tar.lz
dexon-90eb4f1939f7b0389d5784b889cc0e5d2b3451f7.tar.xz
dexon-90eb4f1939f7b0389d5784b889cc0e5d2b3451f7.tar.zst
dexon-90eb4f1939f7b0389d5784b889cc0e5d2b3451f7.zip
Debug output, minor fixes and tweaks
* Script compile length fix * Transition fix
Diffstat (limited to 'ethchain/state_manager.go')
-rw-r--r--ethchain/state_manager.go15
1 files changed, 14 insertions, 1 deletions
diff --git a/ethchain/state_manager.go b/ethchain/state_manager.go
index cec424583..f3fd92913 100644
--- a/ethchain/state_manager.go
+++ b/ethchain/state_manager.go
@@ -181,11 +181,24 @@ func (sm *StateManager) Process(block *Block, dontReact bool) (err error) {
if err != nil {
if len(receipts) == len(block.Receipts()) {
for i, receipt := range block.Receipts() {
- statelogger.Debugf("diff (r) %v ~ %x <=> (c) %v ~ %x (%x)\n", receipt.CumulativeGasUsed, receipt.PostState[0:4], receipts[i].CumulativeGasUsed, receipts[i].PostState[0:4], receipt.Tx.Hash())
+ statelogger.Infof("diff (r) %v ~ %x <=> (c) %v ~ %x (%x)\n", receipt.CumulativeGasUsed, receipt.PostState[0:4], receipts[i].CumulativeGasUsed, receipts[i].PostState[0:4], receipt.Tx.Hash())
}
} else {
statelogger.Warnln("Unable to print receipt diff. Length didn't match", len(receipts), "for", len(block.Receipts()))
}
+ } else {
+ /*
+ for i, receipt := range receipts {
+ gu := new(big.Int)
+ if i != 0 {
+ gu.Sub(receipt.CumulativeGasUsed, receipts[i-1].CumulativeGasUsed)
+ } else {
+ gu.Set(receipt.CumulativeGasUsed)
+ }
+
+ statelogger.Infof("[r] %v ~ %x (%x)\n", gu, receipt.PostState[0:4], receipt.Tx.Hash())
+ }
+ */
}
}()