summaryrefslogtreecommitdiff
path: root/tests/diff/diff_helpers.h
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@edwardthomson.com>2015-05-25 20:03:59 -0400
committerEdward Thomson <ethomson@microsoft.com>2015-06-12 09:39:20 -0400
commit8147b1aff56c0f36f6afee9b8810fc74776e1f58 (patch)
tree298396fb80a973b990e21084e29b0466ceafe5ed /tests/diff/diff_helpers.h
parentac7012a81f0bdc472a3d22393291eb7d130705d1 (diff)
downloadlibgit2-8147b1aff56c0f36f6afee9b8810fc74776e1f58.tar.gz
diff: introduce binary diff callbacks
Introduce a new binary diff callback to provide the actual binary delta contents to callers. Create this data from the diff contents (instead of directly from the ODB) to support binary diffs including the workdir, not just things coming out of the ODB.
Diffstat (limited to 'tests/diff/diff_helpers.h')
-rw-r--r--tests/diff/diff_helpers.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/diff/diff_helpers.h b/tests/diff/diff_helpers.h
index 6bcd1e671..4d3cd3474 100644
--- a/tests/diff/diff_helpers.h
+++ b/tests/diff/diff_helpers.h
@@ -42,6 +42,11 @@ extern int diff_print_file_cb(
float progress,
void *cb_data);
+extern int diff_binary_cb(
+ const git_diff_delta *delta,
+ const git_diff_binary *binary,
+ void *cb_data);
+
extern int diff_hunk_cb(
const git_diff_delta *delta,
const git_diff_hunk *hunk,
@@ -56,6 +61,7 @@ extern int diff_line_cb(
extern int diff_foreach_via_iterator(
git_diff *diff,
git_diff_file_cb file_cb,
+ git_diff_binary_cb binary_cb,
git_diff_hunk_cb hunk_cb,
git_diff_line_cb line_cb,
void *data);