Fix callback leaks

This PR fixes a bunch of memory leaks that would occur when a ruby block that was called in a libgit2 callback would either raise an exception, throw a symbol or simply `break`. See #202 for more details.