summaryrefslogtreecommitdiff
path: root/include/git2/diff.h
diff options
context:
space:
mode:
authorNick Hengeveld <nickh@github.com>2013-11-18 14:03:25 -0800
committerNick Hengeveld <nickh@github.com>2013-11-18 14:03:25 -0800
commitd8e7ffc2a246491aa139875e840fff34c832a739 (patch)
tree26c8ac94f356e381b98274413f4446dc9573aa2e /include/git2/diff.h
parente1ce5249e52e9c5271727d7e2ef5bba4c45277b9 (diff)
downloadlibgit2-d8e7ffc2a246491aa139875e840fff34c832a739.tar.gz
Add content offset to git_diff_line
For additions and deletions, external consumers like subversion can make use of the content offset to generate diffs in their proprietary formats.
Diffstat (limited to 'include/git2/diff.h')
-rw-r--r--include/git2/diff.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/git2/diff.h b/include/git2/diff.h
index a16f86a46..61d288380 100644
--- a/include/git2/diff.h
+++ b/include/git2/diff.h
@@ -446,6 +446,7 @@ struct git_diff_line {
int new_lineno; /** Line number in new file or -1 for deleted line */
int num_lines; /** Number of newline characters in content */
size_t content_len; /** Number of bytes of data */
+ git_off_t content_offset; /** Offset in the original file to the content */
const char *content; /** Pointer to diff text, not NUL-byte terminated */
};