Handle write errors (such as broken pipes) when writing diffs
Josh Triplett
created
Preserve write errors from write calls, and propagate them to the caller
of write_diff, rather than calling .unwrap(). This also avoids
attempting to propagate a panic through a libgit2 callback, which
re-panics.