From fc2ce77945f52aece23c248ae5ef69e00455ab6e Mon Sep 17 00:00:00 2001 From: des Date: Sat, 16 Feb 2008 11:03:37 +0000 Subject: [PATCH] We may get spurious events on an unclosed fd as well. It won't cause any harm, but I still want to catch it early so we get a log entry for it. git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@2491 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- varnish-cache/bin/varnishd/cache_acceptor_kqueue.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c b/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c index 94c4ec7a..8156f62b 100644 --- a/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c +++ b/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c @@ -221,9 +221,9 @@ vca_kev(const struct kevent *kp) #endif spassert(sp->id == kp->ident); spassert(sp->fd == sp->id || sp->fd == -1); - if (sp->fd == -1) { - VSL(SLT_Debug, sp->id, "%s(): got event 0x%04x on closed fd", - __func__, kp->fflags); + if (sp->fd == -1 || kp->fflags == 0) { + VSL(SLT_Debug, sp->id, "%s(): got event 0x%04x on fd %d", + __func__, kp->fflags, sp->fd); return; } if (kp->data > 0) { -- 2.39.5