Merge branch 'mm/fast-import-feature-doc'
[gitweb.git] / diff-lib.c
index f1a9053168dbf0f3b5db2b2e51525828408f88ac..346cac651da725af07a304194d8d8e04b2f080b7 100644 (file)
@@ -474,7 +474,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);
@@ -500,7 +499,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))