libgit2/libgit2sharp — pull request #339 by ethomson (2013-02-14 22:33:29+00:00)
Title: Introduce RepositoryInformation.Message to expose git_repository_message

repository.Info.Message will now reflect `MERGE_MSG` via `git_repository_message`.

Returns `null` if there is no MERGE_MSG file - throwing seems like overkill since this doesn't seem like an exceptional case.

I put buffer allocation in a loop until it's big enough. I don't think there's a real likelihood of getting into a race where MERGE_MSG grows and we need to accommodate that, but this tends to be the way we do this. If you're opposed to this pattern, I'm not tied to it.