I prefer solution 2 as it is the simpler one, but it needs a code comment.
On 06/09/2016 10:02 PM, Oscar Guindzberg wrote: > Hi, > > Retargeting is disabled on bitcoin core for regtest, but enabled on > bitcoinj for regtest. > > See https://github.com/bitcoin/bitcoin/blob/master/src/chainparams.cpp#L257 > See https://github.com/bitcoin/bitcoin/blob/master/src/pow.cpp#L54 > > If you have a bitcoind running on regtest with more than 10k blocks, and > use bitcoinj to sync with it, it will reject blocks starting on block > 10,000. > > I wrote 2 different solutions: > > Solution 1: The way it is implemented on bitcoin core > https://github.com/oscarguindzberg/bitcoinj/commit/1f6049e56077f3707f087f8648d5bfb571771a4e > > Solution 2: Simple solution > https://github.com/oscarguindzberg/bitcoinj/commit/3d322b7a3340f7a16187d649a2e6af9fdc6f0913 > > What solution sounds better? > > -- > Oscar Guindzberg > > -- > You received this message because you are subscribed to the Google > Groups "bitcoinj" group. > To unsubscribe from this group and stop receiving emails from it, send > an email to [email protected] > <mailto:[email protected]>. > For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "bitcoinj" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
