From 5d43db41dcad9ee7683f80b966c8818ffbcd8e07 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Fri, 11 Dec 2020 20:53:32 +0300 Subject: Comment out broken tracing in create_new_target_locked() --- libbuild2/search.cxx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/libbuild2/search.cxx b/libbuild2/search.cxx index b341c85..f52905f 100644 --- a/libbuild2/search.cxx +++ b/libbuild2/search.cxx @@ -279,8 +279,13 @@ namespace build2 target_decl::prereq_new, trace)); - l5 ([&]{trace << (r.second ? "new" : "existing") << " target " << r.first - << " for prerequisite " << pk;}); + // @@ Writing the target (r.first) to the stream ends up in target::ext() + // which tries to slock ctx.targets.mutex_, which is already ulock-ed + // (r.second) by the current thread. This results with + // system_error(errc::resource_deadlock_would_occur). + // + //l5 ([&]{trace << (r.second ? "new" : "existing") << " target " << r.first + // << " for prerequisite " << pk;}); return r; } } -- cgit v1.1