From 49e9668faaf77280b458928da963167a29335c3a Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Mon, 26 Aug 2019 14:48:34 +0200 Subject: Fix bug in scope::find_target_key() --- libbuild2/scope.cxx | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'libbuild2') diff --git a/libbuild2/scope.cxx b/libbuild2/scope.cxx index 0b9d981..d6251a4 100644 --- a/libbuild2/scope.cxx +++ b/libbuild2/scope.cxx @@ -781,7 +781,14 @@ namespace build2 if (n == (ns[0].pair ? 2 : 1)) { name dummy; - return find_target_key (ns[0], n == 2 ? ns[1] : dummy, loc); + target_key r (find_target_key (ns[0], n == 1 ? dummy : ns[1], loc)); + + return target_key { + r.type, + r.dir, + n == 1 ? &empty_dir_path : r.out, + r.name, + move (r.ext)}; } } -- cgit v1.1