# HG changeset patch # User Timo Sirainen # Date 1128163617 -10800 # Node ID 377f69be914ffed130a8b7ae523d31628ebfef35 # Parent 1e053e5e160dbd0cf297838f2c82ab71f64fa120 Fixed fd leak diff -r 1e053e5e160d -r 377f69be914f src/lib/ioloop-notify-dn.c --- 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 |