updated with Bitcoin code develop branch.