adapt to libgit2 > 0.20.0

Staying with the times...

git_repository_discover() takes a git_buf nowadays for storing
the discovered path. Hack gbr_repo_open() to use that.

We should probably move that up and use git_buf for (path,path_size)
to begin with and avoid shuffling back and forth between that and
the caller's (path,path_size)