plugeth/les
Felix Lange 2695fa2213 les: fix crasher in NodeInfo when running as server (#17419)
* les: fix crasher in NodeInfo when running as server

The ProtocolManager computes CHT and Bloom trie roots by asking the
indexers for their current head. It tried to get the indexers from
LesOdr, but no LesOdr instance is created in server mode.

Attempt to fix this by moving the indexers, protocol creation and
NodeInfo to a new lesCommons struct which is embedded into both server
and client.

All this setup code should really be cleaned up, but this is just a
hotfix so we have to do that some other time.

* les: fix commons protocol maker
2018-08-17 13:21:53 +03:00
..
flowcontrol les: fix megacheck warnings (#14941) 2017-08-08 19:31:08 +03:00
api_backend.go accounts, eth, les: blockhash based filtering on all code paths 2018-07-12 18:16:54 +03:00
backend.go les: fix crasher in NodeInfo when running as server (#17419) 2018-08-17 13:21:53 +03:00
bloombits.go build: enable goimports and varcheck linters (#16446) 2018-04-18 00:53:50 +02:00
commons.go les: fix crasher in NodeInfo when running as server (#17419) 2018-08-17 13:21:53 +03:00
distributor_test.go les: changed if-else blocks to conform with golint (#16658) 2018-05-03 11:35:06 +03:00
distributor.go light: CHT and bloom trie indexers working in light mode (#16534) 2018-08-15 22:25:46 +02:00
execqueue_test.go les: fix goroutine leak in execQueue (#14480) 2017-05-16 20:56:02 +02:00
execqueue.go les: fix goroutine leak in execQueue (#14480) 2017-05-16 20:56:02 +02:00
fetcher.go les: add announcement safety check to light fetcher (#17034) 2018-07-04 13:40:20 +03:00
freeclient_test.go les: implement client connection logic (#16899) 2018-08-14 22:44:46 +02:00
freeclient.go les: implement client connection logic (#16899) 2018-08-14 22:44:46 +02:00
handler_test.go all: get rid of error when creating memory database (#16716) 2018-05-09 15:24:25 +03:00
handler.go les: fix crasher in NodeInfo when running as server (#17419) 2018-08-17 13:21:53 +03:00
helper_test.go les: fix crasher in NodeInfo when running as server (#17419) 2018-08-17 13:21:53 +03:00
metrics.go metrics: pull library and introduce ResettingTimer and InfluxDB reporter (#15910) 2018-02-23 11:56:08 +02:00
odr_requests.go trie: fixes to comply with golint (#16771) 2018-05-21 23:41:31 +03:00
odr_test.go light: CHT and bloom trie indexers working in light mode (#16534) 2018-08-15 22:25:46 +02:00
odr.go light: CHT and bloom trie indexers working in light mode (#16534) 2018-08-15 22:25:46 +02:00
peer.go les: add ps.lock.Unlock() before return (#16360) 2018-04-11 11:02:33 +03:00
protocol.go core/rawdb: separate raw database access to own package (#16666) 2018-05-07 14:35:06 +03:00
randselect_test.go all: gofmt -w -s 2017-01-06 15:52:03 +01:00
randselect.go les: changed if-else blocks to conform with golint (#16658) 2018-05-03 11:35:06 +03:00
request_test.go light: CHT and bloom trie indexers working in light mode (#16534) 2018-08-15 22:25:46 +02:00
retrieve.go light: CHT and bloom trie indexers working in light mode (#16534) 2018-08-15 22:25:46 +02:00
server.go les: fix crasher in NodeInfo when running as server (#17419) 2018-08-17 13:21:53 +03:00
serverpool.go les: handle conn/disc/reg logic in the eventloop (#16981) 2018-06-25 11:52:24 +03:00
sync.go core/rawdb: separate raw database access to own package (#16666) 2018-05-07 14:35:06 +03:00
txrelay.go les: code refactoring (#14416) 2017-06-21 12:27:38 +02:00