Code

get_local_heads(): do not return random pointer if there is no head