Changed how logs are being recorded
Logs are now recorded per transactions instead of tossing them out after each transaction. This should also fix an issue with `eth_getFilterLogs` (#629) Also now implemented are the `transactionHash, blockHash, transactionIndex, logIndex` on logs. Closes #654.
This commit is contained in:
@ -557,7 +557,8 @@ func (self *Vm) Run(context *Context, callData []byte) (ret []byte, err error) {
|
||||
}
|
||||
|
||||
data := mem.Get(mStart.Int64(), mSize.Int64())
|
||||
log := &Log{context.Address(), topics, data, self.env.BlockNumber().Uint64()}
|
||||
log := state.NewLog(context.Address(), topics, data, self.env.BlockNumber().Uint64())
|
||||
//log := &Log{context.Address(), topics, data, self.env.BlockNumber().Uint64()}
|
||||
self.env.AddLog(log)
|
||||
|
||||
self.Printf(" => %v", log)
|
||||
|
Reference in New Issue
Block a user