Code

struct rev_info: convert prune_data to struct pathspec
[git.git] / builtin / add.c
index 12b964e642b91863776f161a7b2aab2ec216efcb..5f817ad77f1b3ba247c3b76d1d9a50f7fcc5edee 100644 (file)
@@ -86,7 +86,7 @@ int add_files_to_cache(const char *prefix, const char **pathspec, int flags)
        struct rev_info rev;
        init_revisions(&rev, prefix);
        setup_revisions(0, NULL, &rev, NULL);
-       rev.prune_data = pathspec;
+       init_pathspec(&rev.prune_data, pathspec);
        rev.diffopt.output_format = DIFF_FORMAT_CALLBACK;
        rev.diffopt.format_callback = update_callback;
        data.flags = flags;