82aa883702
TCP/IP stack: * mutt prepares to exec the smtp client: it forks and closes all file descriptors * when the next networking syscall is done, rumpclient detects that the communication fd returned EBADF and does a reconnect, gets descriptor 0 for the socket and descriptor 1 for kqueue * mutt opens the mail file and implicitly assumes it'll get 0-2, but in fact gets 2-4 * mutt execs the smtp agent which tries to read the mail from stdin (rumpclient communication socket) and fails Even if mutt correctly did dup2() things would go south when trying to communicate with the kernel server the next time, since rumpclient would actually be talking with some mail body instead (well, it could work, but in that case you'd need to write *really* weird mails ;). Hence, prevent rumpclient from using the special fd's 0-2 for its purposes. Should fix mutt problem reported by Alexander Nasonov.