]> git.ipfire.org Git - thirdparty/git.git/blobdiff - builtin-pack-objects.c
git_attr(): fix function signature
[thirdparty/git.git] / builtin-pack-objects.c
index 7938202170c1d6110a798da8d58f64ba0c4b4f70..9beff352d5076b6350991d24579b6f9b57d018d5 100644 (file)
@@ -673,7 +673,7 @@ static void setup_delta_attr_check(struct git_attr_check *check)
        static struct git_attr *attr_delta;
 
        if (!attr_delta)
-               attr_delta = git_attr("delta", 5);
+               attr_delta = git_attr("delta");
 
        check[0].attr = attr_delta;
 }
@@ -1630,6 +1630,8 @@ static void ll_find_deltas(struct object_entry **list, unsigned list_size,
        struct thread_params *p;
        int i, ret, active_threads = 0;
 
+       if (!delta_search_threads)      /* --threads=0 means autodetect */
+               delta_search_threads = online_cpus();
        if (delta_search_threads <= 1) {
                find_deltas(list, &list_size, window, depth, processed);
                return;
@@ -2330,11 +2332,6 @@ int cmd_pack_objects(int argc, const char **argv, const char *prefix)
        if (keep_unreachable && unpack_unreachable)
                die("--keep-unreachable and --unpack-unreachable are incompatible.");
 
-#ifdef THREADED_DELTA_SEARCH
-       if (!delta_search_threads)      /* --threads=0 means autodetect */
-               delta_search_threads = online_cpus();
-#endif
-
        if (progress && all_progress_implied)
                progress = 2;