# HG changeset patch # User Timo Sirainen # Date 1195183248 -7200 # Node ID f637a8a1aae7fe452023bdb62661aab492474b7b # Parent 766250fcedd8ad0f82e207629fc77c59526990b1 Don't disable inotify when seeing ESTALE errors. diff -r 766250fcedd8 -r f637a8a1aae7 src/lib/ioloop-notify-inotify.c --- a/src/lib/ioloop-notify-inotify.c Fri Nov 16 05:20:31 2007 +0200 +++ b/src/lib/ioloop-notify-inotify.c Fri Nov 16 05:20:48 2007 +0200 @@ -101,13 +101,11 @@ IN_CREATE | IN_DELETE | IN_DELETE_SELF | IN_MOVE | IN_CLOSE | IN_MODIFY); if (wd < 0) { - if (errno == ENOENT) + /* ESTALE could happen with NFS. Don't bother giving an error + message then. */ + if (errno == ENOENT || errno == ESTALE) return IO_NOTIFY_NOTFOUND; - /* ESTALE could happen with NFS. Don't bother giving an error - message then. */ - if (errno != ESTALE) - i_error("inotify_add_watch(%s) failed: %m", path); ctx->disabled = TRUE; return IO_NOTIFY_DISABLED; }