[dovecot-cvs] dovecot/src/lib-storage/index index-mailbox-check.c,
1.10, 1.11
cras at dovecot.org
cras at dovecot.org
Tue Oct 19 04:47:58 EEST 2004
- Previous message: [dovecot-cvs] dovecot/src/master login-process.c, 1.60,
1.61 master-login-interface.h, 1.5, 1.6
- Next message: [dovecot-cvs] dovecot/src/auth auth-client-connection.c, 1.19,
1.20 auth-client-connection.h, 1.5, 1.6 mech-rpa.c, 1.7,
1.8 mech.c, 1.44, 1.45 mech.h, 1.25, 1.26 passdb-pam.c, 1.17,
1.18 passdb-vpopmail.c, 1.10, 1.11
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /var/lib/cvs/dovecot/src/lib-storage/index
In directory talvi:/tmp/cvs-serv18074/lib-storage/index
Modified Files:
index-mailbox-check.c
Log Message:
If we can't add file to I/O notify list, close the fd so we don't leak.
Fixes IDLE leaking fds with all but Linux.
Index: index-mailbox-check.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/index-mailbox-check.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- index-mailbox-check.c 23 Aug 2004 07:56:29 -0000 1.10
+++ index-mailbox-check.c 19 Oct 2004 01:47:55 -0000 1.11
@@ -74,7 +74,7 @@
{
struct index_notify_file *file;
struct stat st;
- struct io *io;
+ struct io *io = NULL;
struct index_notify_io *aio;
int fd;
@@ -98,6 +98,11 @@
else
file->last_stamp = fstat(fd, &st) < 0 ? 0 : st.st_mtime;
+ if (io == NULL) {
+ /* we couldn't add it to notify list */
+ (void)close(fd);
+ }
+
file->next = ibox->notify_files;
ibox->notify_files = file;
- Previous message: [dovecot-cvs] dovecot/src/master login-process.c, 1.60,
1.61 master-login-interface.h, 1.5, 1.6
- Next message: [dovecot-cvs] dovecot/src/auth auth-client-connection.c, 1.19,
1.20 auth-client-connection.h, 1.5, 1.6 mech-rpa.c, 1.7,
1.8 mech.c, 1.44, 1.45 mech.h, 1.25, 1.26 passdb-pam.c, 1.17,
1.18 passdb-vpopmail.c, 1.10, 1.11
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the dovecot-cvs
mailing list