From: Stephan Bosch Date: Sun, 25 Feb 2018 16:46:55 +0000 (+0100) Subject: lib-program-client: remote: Always shut down the output when all is written. X-Git-Tag: 2.3.9~2099 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9799593989c402e3ec0ae55c60e1f58f8838d945;p=thirdparty%2Fdovecot%2Fcore.git lib-program-client: remote: Always shut down the output when all is written. Before, this step was omitted when dot streams were used. However, shutting down the output is necessary no matter what. Otherwise, the receiving end will not see that no more input will follow, causing deadlock. --- diff --git a/src/lib-program-client/program-client-remote.c b/src/lib-program-client/program-client-remote.c index 110e4d7947..6e5a1d9ee0 100644 --- a/src/lib-program-client/program-client-remote.c +++ b/src/lib-program-client/program-client-remote.c @@ -527,8 +527,6 @@ program_client_remote_close_output(struct program_client *pclient) int fd_out = pclient->fd_out, fd_in = pclient->fd_in; pclient->fd_out = -1; - if (fd_out >= 0 && pclient->set.use_dotstream) - return 1; /* Shutdown output; program stdin will get EOF */ if (fd_out >= 0) {