aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/cc/link-rule.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'libbuild2/cc/link-rule.cxx')
-rw-r--r--libbuild2/cc/link-rule.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/libbuild2/cc/link-rule.cxx b/libbuild2/cc/link-rule.cxx
index ccb8dc6..6969ef2 100644
--- a/libbuild2/cc/link-rule.cxx
+++ b/libbuild2/cc/link-rule.cxx
@@ -2127,9 +2127,12 @@ namespace build2
}
catch (const io_error& e)
{
- if (pr.wait ()) // Ignore if child failed.
+ if (run_wait (args, pr))
fail << "unable to pipe resource file to " << args[0]
<< ": " << e;
+
+ // If the child process has failed then assume the io error
+ // was caused by that and let run_finish() deal with it.
}
run_finish (args, pr);