crash fix: use branch->SetAddress instead of leaf, consistent code arrangement
Factor out ensure_dictionary into libdrillbit, fix vector copying.