[dovecot-cvs] dovecot/src/master auth-process.c,1.6,1.7
cras at procontrol.fi
cras at procontrol.fi
Mon Nov 25 15:19:57 EET 2002
Update of /home/cvs/dovecot/src/master
In directory danu:/tmp/cvs-serv25886/master
Modified Files:
auth-process.c
Log Message:
Moved login listener handle to fd 3 from 1 (stdout), because vpopmail could
try writing into it.
Index: auth-process.c
===================================================================
RCS file: /home/cvs/dovecot/src/master/auth-process.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- auth-process.c 20 Nov 2002 19:20:23 -0000 1.6
+++ auth-process.c 25 Nov 2002 13:19:55 -0000 1.7
@@ -211,12 +211,14 @@
if (dup2(fd[1], 0) < 0)
i_fatal("login: dup2() failed: %m");
- /* move login communication handle to 1 */
- if (dup2(listen_fd, 1) < 0)
+ /* move login communication handle to 3 */
+ if (dup2(listen_fd, 3) < 0)
i_fatal("login: dup2() failed: %m");
- /* set /dev/null handle into 2, so if something is printed into
- stderr it can't go anywhere where it could cause harm */
+ /* set /dev/null handle into 1 and 2, so if something is printed into
+ stdout/stderr it can't go anywhere where it could cause harm */
+ if (dup2(null_fd, 1) < 0)
+ i_fatal("login: dup2() failed: %m");
if (dup2(null_fd, 2) < 0)
i_fatal("login: dup2() failed: %m");
More information about the dovecot-cvs
mailing list