1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-12-23 17:34:00 +03:00

Merge pull request #272 from poettering/nspawn-flush-copy-fd

nspawn: when exiting, flush all remaining bytes from the pty to stdout
This commit is contained in:
Daniel Mack 2015-06-18 00:34:22 +02:00
commit 867a99b406

View File

@ -4972,6 +4972,10 @@ finish:
if (pid > 0)
kill(pid, SIGKILL);
/* Try to flush whatever is still queued in the pty */
if (master >= 0)
(void) copy_bytes(master, STDOUT_FILENO, (off_t) -1, false);
loop_remove(loop_nr, &image_fd);
if (remove_subvol && arg_directory) {