Mercurial > dovecot > original-hg > dovecot-1.2
changeset 3634:377f69be914f HEAD
Fixed fd leak
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Sat, 01 Oct 2005 13:46:57 +0300 |
parents | 1e053e5e160d |
children | c12df370e1b2 |
files | src/lib/ioloop-notify-dn.c |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib/ioloop-notify-dn.c Sat Oct 01 12:48:11 2005 +0300 +++ b/src/lib/ioloop-notify-dn.c Sat Oct 01 13:46:57 2005 +0300 @@ -76,9 +76,10 @@ if (errno == EINVAL) { /* dnotify not in kernel. disable it. */ ctx->disabled = TRUE; - return NULL; + } else { + i_error("fcntl(F_SETSIG) failed: %m"); } - i_error("fcntl(F_SETSIG) failed: %m"); + (void)close(fd); return NULL; } if (fcntl(fd, F_NOTIFY, DN_CREATE | DN_DELETE | DN_RENAME |