X-Git-Url: http://git.ipfire.org/?a=blobdiff_plain;f=diff-lib.c;h=0a95763063494914e30b326a87d5e007765d8fcb;hb=9a0872744315da67db3c81eb9270751e31fcc8f5;hp=b6f4b21637fe66a614a0dd6581f90fc12e80a6f8;hpb=f4c52a05277f8f5901f7663f6ab339271b814872;p=thirdparty%2Fgit.git diff --git a/diff-lib.c b/diff-lib.c index b6f4b21637..0a95763063 100644 --- a/diff-lib.c +++ b/diff-lib.c @@ -476,7 +476,6 @@ static int diff_cache(struct rev_info *revs, opts.dst_index = NULL; opts.pathspec = &revs->diffopt.pathspec; opts.pathspec->recursive = 1; - opts.pathspec->max_depth = -1; init_tree_desc(&t, tree->buffer, tree->size); return unpack_trees(1, &t, &opts); @@ -502,7 +501,7 @@ int do_diff_cache(const unsigned char *tree_sha1, struct diff_options *opt) struct rev_info revs; init_revisions(&revs, NULL); - init_pathspec(&revs.prune_data, opt->pathspec.raw); + copy_pathspec(&revs.prune_data, &opt->pathspec); revs.diffopt = *opt; if (diff_cache(&revs, tree_sha1, NULL, 1))