Set a boolean to indicate whether we really have a competing validation (#1641)
Set a boolean to indicate whether we really have a competing validation (#1641)

This fixes an edge cases which was showing up in the parallel.py --extensive
script and causing a failure there.  It is however a real problem and
does show up during IBD on occasion.

Due to the multi-threading in the BU client, during IBD the chain can
momentarily catch up to the headers giving the appearance that the
chain is nearly sync'd. This causes us to, at time, execute the section
of code which either ends a validation or kills a valiation thread
because we've erroneously assumed we are having a block race. To fix
this we can just introduce a new boolean, fCompeting, which indicates
that we are indeed having a real race and if not then do not end
any validations or kill any threads.
BitcoinUnlimited/BitcoinUnlimited,Justaphf/BitcoinUnlimited,Justaphf/BitcoinUnlimited,Justaphf/BitcoinUnlimited,BitcoinUnlimited/BitcoinUnlimited,Justaphf/BitcoinUnlimited,Justaphf/BitcoinUnlimited,BitcoinUnlimited/BitcoinUnlimited,Justaphf/BitcoinUnlimited,BitcoinUnlimited/BitcoinUnlimited,BitcoinUnlimited/BitcoinUnlimited,BitcoinUnlimited/BitcoinUnlimited