aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/cc/msvc.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2020-07-17 17:17:55 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2020-07-17 17:17:55 +0200
commit4ca5a5bc2991438602d3b1fdb56b91d2b425c52d (patch)
treeb9a2f6f801031af9299bfc45095eac1eb3ceb495 /libbuild2/cc/msvc.cxx
parentab4a9ef42e8f1070dcb5d783a5afccd2f685e86d (diff)
Fix race in path/mtime assignment and file_rule::match()
Diffstat (limited to 'libbuild2/cc/msvc.cxx')
-rw-r--r--libbuild2/cc/msvc.cxx8
1 files changed, 2 insertions, 6 deletions
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 ());
}
}