diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2003-12-02 06:51:58 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2003-12-02 06:51:58 +0800 |
commit | 9d8f9dea7be5a8d8973198eb5367d9f055f74974 (patch) | |
tree | ff9d7843085dca33af57f8d2f6d22684fae4906f /camel/camel-process.c | |
parent | 7a7855e2879922b371597b25c27fd97d79dd165a (diff) | |
download | gsoc2013-evolution-9d8f9dea7be5a8d8973198eb5367d9f055f74974.tar.gz gsoc2013-evolution-9d8f9dea7be5a8d8973198eb5367d9f055f74974.tar.zst gsoc2013-evolution-9d8f9dea7be5a8d8973198eb5367d9f055f74974.zip |
Start at fd = 3.
2003-12-01 Jeffrey Stedfast <fejj@ximian.com>
* camel-process.c (camel_process_fork): Start at fd = 3.
* camel-gpg-context.c (gpg_ctx_op_start): Same.
* camel-filter-driver.c (pipe_to_system): Same.
* camel-filter-search.c (run_command): Start at fd = 3.
svn path=/trunk/; revision=23549
Diffstat (limited to 'camel/camel-process.c')
-rw-r--r-- | camel/camel-process.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/camel/camel-process.c b/camel/camel-process.c index 9e2d9657dd..04de281294 100644 --- a/camel/camel-process.c +++ b/camel/camel-process.c @@ -79,10 +79,8 @@ camel_process_fork (const char *path, char **argv, int *infd, int *outfd, int *e setsid (); if ((maxfd = sysconf (_SC_OPEN_MAX)) > 0) { - for (i = 0; i < maxfd; i++) { - if (i != STDIN_FILENO && i != STDOUT_FILENO && i != STDERR_FILENO) - fcntl (i, F_SETFD, FD_CLOEXEC); - } + for (i = 3; i < maxfd; i++) + fcntl (i, F_SETFD, FD_CLOEXEC); } execv (path, argv); |