From 048bcc1604a7e8aca666e219c0fdc3cd5517029e Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Fri, 2 Jun 2023 06:10:34 +0200 Subject: Fix data race in library metadata protocol logic --- libbuild2/target.hxx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'libbuild2/target.hxx') diff --git a/libbuild2/target.hxx b/libbuild2/target.hxx index d4ad780..69714fc 100644 --- a/libbuild2/target.hxx +++ b/libbuild2/target.hxx @@ -940,7 +940,11 @@ namespace build2 // (e.g., in match data) with a few well-known execeptions (see // group_recipe and inner_recipe). // - // Note that the recipe may modify this list. @@ TMP TSAN issue + // Note that the recipe may modify this list during execute. Normally this + // would be just blanking out of ad hoc prerequisites, in which case check + // for ad hoc first and for not NULL second if accessing prerequisites of + // targets that you did not execute (see the library metadata protocol in + // cc for an example). // mutable action_state prerequisite_targets; -- cgit v1.1