bitcoin/bitcoin — pull request #3087 by sipa (2013-10-13 20:20:06+00:00)
Title: Stop using the redundant 'best invalid work' record

As block index entries have a flag for marking invalid blocks, the 'best invalid work' information can be derived from there. In addition, remove the global from main.h.

Depends on #3077.