Directly generate a patch from the difference between two buffers.
This is just like git_diff_buffers()
except it generates a patch
object for the difference instead of directly making callbacks. You can
use the standard git_patch
accessor functions to read the patch
data, and you must call git_patch_free()
on the patch when done.
Raw data for old side of diff, or NULL for empty
Length of the raw data for old side of the diff
Treat old buffer as if it had this filename; can be NULL
Raw data for new side of diff, or NULL for empty
Length of raw data for new side of diff
Treat buffer as if it had this filename; can be NULL
0 on success or error code < 0