[stable] Backports (#8919)

* Fixed AuthorityRound deadlock on shutdown, closes #8088 (#8803)

* CI: Fix docker tags (#8822)

* scripts: enable docker builds for beta and stable

* scripts: docker latest should be beta not master

* scripts: docker latest is master

* Fix concurrent access to signer queue (#8854)

* Fix concurrent access to signer queue

* Put request back to the queue if confirmation failed

* typo: fix docs and rename functions to be more specific

`request_notify` does not need to be public, and it's renamed to `notify_result`.
`notify` is renamed to `notify_message`.

* Change trace info "Transaction" -> "Request"

* Add new ovh bootnodes and fix port for foundation bootnode 3.2 (#8886)

* Add new ovh bootnodes and fix port for foundation bootnode 3.2

* Remove old bootnodes.

* Remove duplicate 1118980bf48b0a3640bdba04e0fe78b1add18e1cd99bf22d53daac1fd9972ad650df52176e7c7d89d1114cfef2bc23a2959aa54998a46afcf7d91809f0855082

* Block 0 is valid in queries (#8891)

Early exit for block nr 0 leads to spurious error about pruning: `…your node is running with state pruning…`.

Fixes #7547, #8762

* update jsonrpc libs, fixed ipc leak, closes #8774 (#8876)

Instead of cherrypicking 8b78141b20b75da508ce82bccc9286e3d7858a7b, just ran cargo update -p jsonrpc-core

* Add ETC Cooperative-run load balanced parity node (#8892)

* Minor fix in chain supplier and light provider (#8906)

* fix chain supplier increment

* fix light provider block_headers
This commit is contained in:
Andrew Jones
2018-06-19 07:09:08 +01:00
committed by Afri Schoedon
parent 718b398a17
commit ba79cad670
12 changed files with 184 additions and 133 deletions

View File

@@ -1579,7 +1579,7 @@ impl ChainSync {
let max_count = cmp::min(MAX_HEADERS_TO_SEND, max_headers);
let mut count = 0;
let mut data = Bytes::new();
let inc = (skip + 1) as BlockNumber;
let inc = skip.saturating_add(1) as BlockNumber;
let overlay = io.chain_overlay().read();
while number <= last && count < max_count {
@@ -1598,10 +1598,10 @@ impl ChainSync {
if number <= inc || number == 0 {
break;
}
number -= inc;
number = number.saturating_sub(inc);
}
else {
number += inc;
number = number.saturating_add(inc);
}
}
let mut rlp = RlpStream::new_list(count as usize);