Properly uninstall filters. Mining issue fixed #closes #365

* Added an additional tx state which is used to get the current nonce
* Refresh transient state each time a new canonical block is found
* Properly uninstall filters. Fixes a possible crash in RPC
This commit is contained in:
obscuren
2015-02-23 15:43:41 +01:00
parent 20aa6dde06
commit b2a225a52e
6 changed files with 59 additions and 22 deletions

View File

@@ -127,6 +127,10 @@ func (self *Whisper) Watch(opts Filter) int {
})
}
func (self *Whisper) Unwatch(id int) {
self.filters.Uninstall(id)
}
func (self *Whisper) Messages(id int) (messages []*Message) {
filter := self.filters.Get(id)
if filter != nil {