diff options
author | John Keeping | 2013-03-02 12:32:10 +0000 |
---|---|---|
committer | Jason A. Donenfeld | 2013-03-02 10:38:03 -0500 |
commit | bfc14d067da0fdf65f306fcd9a65829d9694dbeb (patch) | |
tree | 71097af45a55844f67f4af411d461903f5d60519 /shared.c | |
parent | c0a92e82da3063efc230538ba109ff95aa59589a (diff) | |
download | cgit-bfc14d067da0fdf65f306fcd9a65829d9694dbeb.tar.gz cgit-bfc14d067da0fdf65f306fcd9a65829d9694dbeb.tar.bz2 cgit-bfc14d067da0fdf65f306fcd9a65829d9694dbeb.zip |
Update git to v1.7.5.4
Some changes to diff options:
- no_merges has become the more general max_parents
- path restriction now uses struct pathspec
Signed-off-by: John Keeping <john@keeping.me.uk>
Diffstat (limited to 'shared.c')
-rw-r--r-- | shared.c | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -307,7 +307,7 @@ void cgit_diff_tree(const unsigned char *old_sha1, | |||
307 | filepair_fn fn, const char *prefix, int ignorews) | 307 | filepair_fn fn, const char *prefix, int ignorews) |
308 | { | 308 | { |
309 | struct diff_options opt; | 309 | struct diff_options opt; |
310 | int prefixlen; | 310 | struct pathspec_item item; |
311 | 311 | ||
312 | diff_setup(&opt); | 312 | diff_setup(&opt); |
313 | opt.output_format = DIFF_FORMAT_CALLBACK; | 313 | opt.output_format = DIFF_FORMAT_CALLBACK; |
@@ -319,10 +319,10 @@ void cgit_diff_tree(const unsigned char *old_sha1, | |||
319 | opt.format_callback = cgit_diff_tree_cb; | 319 | opt.format_callback = cgit_diff_tree_cb; |
320 | opt.format_callback_data = fn; | 320 | opt.format_callback_data = fn; |
321 | if (prefix) { | 321 | if (prefix) { |
322 | opt.nr_paths = 1; | 322 | item.match = prefix; |
323 | opt.paths = &prefix; | 323 | item.len = strlen(prefix); |
324 | prefixlen = strlen(prefix); | 324 | opt.pathspec.nr = 1; |
325 | opt.pathlens = &prefixlen; | 325 | opt.pathspec.items = &item; |
326 | } | 326 | } |
327 | diff_setup_done(&opt); | 327 | diff_setup_done(&opt); |
328 | 328 | ||