diff options
Diffstat (limited to 'mailutils')
-rw-r--r-- | mailutils/mime.c | 2 | ||||
-rw-r--r-- | mailutils/sendmail.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/mailutils/mime.c b/mailutils/mime.c index dd81139f2..17d0f9d80 100644 --- a/mailutils/mime.c +++ b/mailutils/mime.c | |||
@@ -293,7 +293,7 @@ static int parse(const char *boundary, char **argv) | |||
293 | } | 293 | } |
294 | // parent dumps to fd[1] | 294 | // parent dumps to fd[1] |
295 | close(fd[0]); | 295 | close(fd[0]); |
296 | fp = fdopen(fd[1], "w"); | 296 | fp = xfdopen_for_write(fd[1]); |
297 | signal(SIGPIPE, SIG_IGN); // ignore EPIPE | 297 | signal(SIGPIPE, SIG_IGN); // ignore EPIPE |
298 | // or create a file for dump | 298 | // or create a file for dump |
299 | } else { | 299 | } else { |
diff --git a/mailutils/sendmail.c b/mailutils/sendmail.c index 2f99df6c0..4b58a78eb 100644 --- a/mailutils/sendmail.c +++ b/mailutils/sendmail.c | |||
@@ -93,7 +93,7 @@ int sendmail_main(int argc UNUSED_PARAM, char **argv) | |||
93 | 93 | ||
94 | // save initial stdin since body is piped! | 94 | // save initial stdin since body is piped! |
95 | xdup2(STDIN_FILENO, 3); | 95 | xdup2(STDIN_FILENO, 3); |
96 | G.fp0 = fdopen(3, "r"); | 96 | G.fp0 = xfdopen_for_read(3); |
97 | 97 | ||
98 | // parse options | 98 | // parse options |
99 | // -f is required. -H and -S are mutually exclusive | 99 | // -f is required. -H and -S are mutually exclusive |