From: Timo Sirainen Date: Thu, 11 Sep 2008 14:06:29 +0000 (+0300) Subject: Mail cache: Don't warn if dotlocking fails due to timeout (non-dotlocking already... X-Git-Tag: 1.2.alpha2~59 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=4aae8acbcfa9cac96b4af39bfabcbe569e804827;p=thirdparty%2Fdovecot%2Fcore.git Mail cache: Don't warn if dotlocking fails due to timeout (non-dotlocking already didn't). --HG-- branch : HEAD --- diff --git a/src/lib-index/mail-cache.c b/src/lib-index/mail-cache.c index d69a41823e..e7fdf58568 100644 --- a/src/lib-index/mail-cache.c +++ b/src/lib-index/mail-cache.c @@ -478,12 +478,15 @@ static int mail_cache_lock_file(struct mail_cache *cache, bool nonblock) ret = file_dotlock_create(&cache->dotlock_settings, cache->filepath, flags, &cache->dotlock); - if (ret <= 0) { + if (ret < 0) { mail_cache_set_syscall_error(cache, "file_dotlock_create()"); } } + /* don't bother warning if locking failed due to a timeout. since cache + updating isn't all that important we're using a very short timeout + so it can be triggered sometimes on heavy load */ if (ret <= 0) return ret;