From db53f5d54643e2f83f5de2368c1e2b26c5e7643e Mon Sep 17 00:00:00 2001 From: phk Date: Sun, 21 Dec 2008 18:33:30 +0000 Subject: [PATCH] Assert fcntl(2) have not failed. git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3488 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- varnish-cache/bin/varnishd/cache_acceptor_kqueue.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c b/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c index 8ffa1894..22645e80 100644 --- a/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c +++ b/varnish-cache/bin/varnishd/cache_acceptor_kqueue.c @@ -209,8 +209,10 @@ vca_kqueue_init(void) int i; i = fcntl(vca_pipes[0], F_GETFL); + assert(i != -1); i |= O_NONBLOCK; i = fcntl(vca_pipes[0], F_SETFL, i); + assert(i != -1); AZ(pthread_create(&vca_kqueue_thread, NULL, vca_kqueue_main, NULL)); } -- 2.39.5