summaryrefslogtreecommitdiff
path: root/color.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2017-09-10 08:08:22 (GMT)
committerJunio C Hamano <gitster@pobox.com>2017-09-10 08:08:22 (GMT)
commita48ce378585054f2ae3b2f0e18346ab005290524 (patch)
treebfb2fab6ffc87128bd4cbc03ff40a83ce07f8001 /color.c
parent3ec7d702a89c647ddf42a59bc3539361367de9d5 (diff)
parent6cdf8a7929688ea5702ab53f450d038e973e64e1 (diff)
downloadgit-a48ce378585054f2ae3b2f0e18346ab005290524.zip
git-a48ce378585054f2ae3b2f0e18346ab005290524.tar.gz
git-a48ce378585054f2ae3b2f0e18346ab005290524.tar.bz2
Merge branch 'ma/ts-cleanups'
Assorted bugfixes and clean-ups. * ma/ts-cleanups: ThreadSanitizer: add suppressions strbuf_setlen: don't write to strbuf_slopbuf pack-objects: take lock before accessing `remaining` convert: always initialize attr_action in convert_attrs
Diffstat (limited to 'color.c')
-rw-r--r--color.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/color.c b/color.c
index 7aa8b07..9ccd954 100644
--- a/color.c
+++ b/color.c
@@ -338,6 +338,13 @@ static int check_auto_color(void)
int want_color(int var)
{
+ /*
+ * NEEDSWORK: This function is sometimes used from multiple threads, and
+ * we end up using want_auto racily. That "should not matter" since
+ * we always write the same value, but it's still wrong. This function
+ * is listed in .tsan-suppressions for the time being.
+ */
+
static int want_auto = -1;
if (var < 0)