]> gitweb.ps.run Git - ps-cgit/blobdiff - shared.c
Update git to v1.7.5.4
[ps-cgit] / shared.c
index 8e5ae4811d13f104530e4980967b5dc0d79d3529..0967f922de18c8b132d40577b89ae16c0722546c 100644 (file)
--- a/shared.c
+++ b/shared.c
@@ -307,7 +307,7 @@ void cgit_diff_tree(const unsigned char *old_sha1,
                    filepair_fn fn, const char *prefix, int ignorews)
 {
        struct diff_options opt;
-       int prefixlen;
+       struct pathspec_item item;
 
        diff_setup(&opt);
        opt.output_format = DIFF_FORMAT_CALLBACK;
@@ -319,10 +319,10 @@ void cgit_diff_tree(const unsigned char *old_sha1,
        opt.format_callback = cgit_diff_tree_cb;
        opt.format_callback_data = fn;
        if (prefix) {
-               opt.nr_paths = 1;
-               opt.paths = &prefix;
-               prefixlen = strlen(prefix);
-               opt.pathlens = &prefixlen;
+               item.match = prefix;
+               item.len = strlen(prefix);
+               opt.pathspec.nr = 1;
+               opt.pathspec.items = &item;
        }
        diff_setup_done(&opt);