From f91dcce80beb48bf8b444b472f4820a4ff2b33e5 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 13 Jan 2021 12:48:42 +0200 Subject: Make sure we don't work any existing tasks when building in module context --- libbuild2/module.cxx | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'libbuild2/module.cxx') diff --git a/libbuild2/module.cxx b/libbuild2/module.cxx index b2b4036..9a7975d 100644 --- a/libbuild2/module.cxx +++ b/libbuild2/module.cxx @@ -415,6 +415,12 @@ namespace build2 // context& ctx (*bs.ctx.module_context); + // Mark the queue so that we don't work any tasks that may already be + // there (we could be called in strange ways, for example, as part of + // match via dir_search()). + // + scheduler::queue_mark qm (ctx.sched); + // Load the imported project in the module context. // pair lr ( -- cgit v1.1