Author

Topic: Are CBlock and CBlockHeader compatible with older versions of BTC? (Read 673 times)

hero member
Activity: 602
Merit: 501
I work extensively with the new BTC codebase, if you intend to rebase, your best option is to just copy the params of your old chain, then use a copy of the old chain to bootstrap.

An actual manual rebase is a hell of a lot of work and completely unnecessary unless you made some very significant changes.

Note that the changes to CBlock are just the beggining, there's mempool, script and CCoinsview to worry about and considering that these changes were made over a long time by a large dev group double checking each other's work, it's higly unlikely you can pull off a proper and functional rebase alone.

I tried bringing PoS to 2015 standards and gave it up as a bad job
hero member
Activity: 690
Merit: 501
Hi,

I am trying to rebase some old btc code the current. It is before CBlock and CBlockHeader were split into two separate classes.

When it syncs and receives a 'block' message from a peer, it gets an error:

Code:
if (strCommand == "block"){
    CBlock block;
    vRecv >> block;
...

Shifting vRecv into block gives me an error.
Code:
ReadCompactSize(): size too large
.

However, if I make 'block' a CBlockHeader, it all works. (Except it doesn't have the tx list and everything else I need).
Jump to: