From b1d70d576caff07c738d7bd4b76fb24f70c91c89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Henry?= Date: Wed, 9 May 2018 23:09:56 +0200 Subject: [PATCH] Shell: stricter fitness check on block injection --- src/lib_shell/chain_validator.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib_shell/chain_validator.ml b/src/lib_shell/chain_validator.ml index 9c32186eb..19aacf11e 100644 --- a/src/lib_shell/chain_validator.ml +++ b/src/lib_shell/chain_validator.ml @@ -400,7 +400,7 @@ let validate_block w ?(force = false) hash block operations = Chain.head nv.parameters.chain_state >>= fun head -> let head = State.Block.header head in if - force || Fitness.(head.shell.fitness <= block.shell.fitness) + force || Fitness.(head.shell.fitness < block.shell.fitness) then Block_validator.validate ~canceler:(Worker.canceler w)