From 4ca5a5bc2991438602d3b1fdb56b91d2b425c52d Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Fri, 17 Jul 2020 17:17:55 +0200 Subject: Fix race in path/mtime assignment and file_rule::match() --- libbuild2/cc/msvc.cxx | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'libbuild2/cc/msvc.cxx') diff --git a/libbuild2/cc/msvc.cxx b/libbuild2/cc/msvc.cxx index 20239c7..8f0a853 100644 --- a/libbuild2/cc/msvc.cxx +++ b/libbuild2/cc/msvc.cxx @@ -528,10 +528,7 @@ namespace build2 // T* t; common::insert_library (p.scope->ctx, t, name, d, ld, e, exist, trace); - - t->mtime (mt); - t->path (move (f)); - + t->path_mtime (move (f), mt); return t; } @@ -603,8 +600,7 @@ namespace build2 // Presumably there is a DLL somewhere, we just don't know where. // - s->mtime (i->mtime ()); - s->path (path ()); + s->path_mtime (path (), i->mtime ()); } } -- cgit v1.1