rebase: fix fork-point with zero arguments
[gitweb.git] / combine-diff.c
index 4fc16ad4f35c558daf5bf96865801828d10b4b9b..3b92c44880228a94f71a428b0f11bb1caf693c67 100644 (file)
@@ -1306,7 +1306,7 @@ void diff_tree_combined(const unsigned char *sha1,
        int i, num_paths, needsep, show_log_first, num_parent = parents->nr;
 
        diffopts = *opt;
-       diff_tree_setup_paths(diffopts.pathspec.raw, &diffopts);
+       copy_pathspec(&diffopts.pathspec, &opt->pathspec);
        diffopts.output_format = DIFF_FORMAT_NO_OUTPUT;
        DIFF_OPT_SET(&diffopts, RECURSIVE);
        DIFF_OPT_CLR(&diffopts, ALLOW_EXTERNAL);
@@ -1378,7 +1378,7 @@ void diff_tree_combined(const unsigned char *sha1,
                free(tmp);
        }
 
-       diff_tree_release_paths(&diffopts);
+       free_pathspec(&diffopts.pathspec);
 }
 
 void diff_tree_combined_merge(const struct commit *commit, int dense,