From 5037ffcfcacc13d0cb32f0e7b1c0677fb9ffcd2b Mon Sep 17 00:00:00 2001 From: phk Date: Mon, 8 Oct 2007 07:50:31 +0000 Subject: [PATCH] Use HTC_Rx() directly instead of vca_pollsession() wrapper git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@2082 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- varnish-cache/bin/varnishd/cache_acceptor_kqueue.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c b/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c index 218c0f3d..b83aaa55 100644 --- a/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c +++ b/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c @@ -98,14 +98,15 @@ vca_kev(const struct kevent *kp) } CAST_OBJ_NOTNULL(sp, kp->udata, SESS_MAGIC); if (kp->data > 0) { - i = vca_pollsession(sp); - if (i == -1) - return; + i = HTC_Rx(sp->htc); + if (i == 0) + return; /* more needed */ VTAILQ_REMOVE(&sesshead, sp, list); - if (i == 0) { + if (i > 0) { vca_kq_sess(sp, EV_DELETE); vca_handover(sp, i); } else { + vca_close_session(sp, "err/poll"); SES_Delete(sp); } return; -- 2.39.5