Capture all of the child output when it fails to start

we only forwarded the result from a single read(), which might have
missed information on the actual error.
parent 4ed6181f
......@@ -426,7 +426,9 @@ mgt_launch_child(struct cli *cli)
assert(u == CLIS_COMMS);
pidr = waitpid(pid, &i, 0);
assert(pidr == pid);
(void)VLU_Fd(child_std_vlu, child_output);
do {
i = VLU_Fd(child_std_vlu, child_output);
} while (i == 0);
MGT_Complain(C_ERR, "Child failed on launch");
exit(1); // XXX Harsh ?
} else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment