Merge pull request #5480 from libgit2/ethomson/coverity repo::open: ensure we can open the repository