summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--builtin/pack-objects.c4
-rwxr-xr-xt/t5300-pack-object.sh2
2 files changed, 4 insertions, 2 deletions
diff --git a/builtin/pack-objects.c b/builtin/pack-objects.c
index 0fe35d1..f1baf05 100644
--- a/builtin/pack-objects.c
+++ b/builtin/pack-objects.c
@@ -2472,8 +2472,10 @@ static int git_pack_config(const char *k, const char *v, void *cb)
die("invalid number of threads specified (%d)",
delta_search_threads);
#ifdef NO_PTHREADS
- if (delta_search_threads != 1)
+ if (delta_search_threads != 1) {
warning("no threads support, ignoring %s", k);
+ delta_search_threads = 0;
+ }
#endif
return 0;
}
diff --git a/t/t5300-pack-object.sh b/t/t5300-pack-object.sh
index 6ed23ee..9c68b99 100755
--- a/t/t5300-pack-object.sh
+++ b/t/t5300-pack-object.sh
@@ -447,7 +447,7 @@ test_expect_success !PTHREADS,C_LOCALE_OUTPUT 'pack-objects --threads=N or pack.
git -c pack.threads=2 pack-objects --stdout --all </dev/null >/dev/null 2>err &&
grep ^warning: err >warnings &&
- test_must_fail test_line_count = 1 warnings &&
+ test_line_count = 1 warnings &&
grep -F "no threads support, ignoring pack.threads" err &&
git -c pack.threads=2 pack-objects --threads=4 --stdout --all </dev/null >/dev/null 2>err &&