les, core/bloombits: post-LES/2 fixes (#15391)

* les: fix topic ID

* core/bloombits: fix interface conversion
pull/15398/head
Felföldi Zsolt 7 years ago committed by Péter Szilágyi
parent 6dafec0666
commit 8d434f6a6f
  1. 5
      core/bloombits/matcher.go
  2. 2
      les/backend.go

@ -534,7 +534,10 @@ func (s *MatcherSession) Close() {
// Error returns any failure encountered during the matching session. // Error returns any failure encountered during the matching session.
func (s *MatcherSession) Error() error { func (s *MatcherSession) Error() error {
return s.err.Load().(error) if err := s.err.Load(); err != nil {
return err.(error)
}
return nil
} }
// AllocateRetrieval assigns a bloom bit index to a client process that can either // AllocateRetrieval assigns a bloom bit index to a client process that can either

@ -145,7 +145,7 @@ func lesTopic(genesisHash common.Hash, protocolVersion uint) discv5.Topic {
default: default:
panic(nil) panic(nil)
} }
return discv5.Topic(name + common.Bytes2Hex(genesisHash.Bytes()[0:8])) return discv5.Topic(name + "@" + common.Bytes2Hex(genesisHash.Bytes()[0:8]))
} }
type LightDummyAPI struct{} type LightDummyAPI struct{}

Loading…
Cancel
Save