diff options
-rw-r--r-- | build2/cc/link.cxx | 2 | ||||
-rw-r--r-- | build2/target.cxx | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/build2/cc/link.cxx b/build2/cc/link.cxx index 80eb995..4e22151 100644 --- a/build2/cc/link.cxx +++ b/build2/cc/link.cxx @@ -236,7 +236,7 @@ namespace build2 path b (ls.dir); path cp; // Clean pattern. { - if (pfx == nullptr) + if (pfx == nullptr || pfx[0] == '\0') { b /= ls.name; } diff --git a/build2/target.cxx b/build2/target.cxx index d3af0c5..062db06 100644 --- a/build2/target.cxx +++ b/build2/target.cxx @@ -583,7 +583,7 @@ namespace build2 { path_type p (dir); - if (np == nullptr) + if (np == nullptr || np[0] == '\0') p /= name; else { |