From owner-freebsd-hackers Mon Aug 26 23:47:58 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B749837B405 for ; Mon, 26 Aug 2002 23:47:55 -0700 (PDT) Received: from host217-41-35-87.in-addr.btopenworld.com (host217-41-35-87.in-addr.btopenworld.com [217.41.35.87]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3D56643E42 for ; Mon, 26 Aug 2002 23:47:55 -0700 (PDT) (envelope-from dom@host217-41-35-87.in-addr.btopenworld.com) Received: by gallium.localdomain (Postfix, from userid 1001) id 217D028E; Tue, 27 Aug 2002 07:47:56 +0100 (BST) Date: Tue, 27 Aug 2002 07:47:56 +0100 From: Dominic Marks To: Ian Dowse Cc: freebsd-hackers@freebsd.org Subject: Re: kevent and pipes interaction on 4.6-STABLE Message-ID: <20020827064756.GA239@gallium> References: <20020826225851.GA93947@gallium> <200208270041.aa72777@salmon.maths.tcd.ie> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200208270041.aa72777@salmon.maths.tcd.ie> User-Agent: Mutt/1.5.1i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, Aug 27, 2002 at 12:41:21AM +0100, Ian Dowse wrote: > In message <20020826225851.GA93947@gallium>, Dominic Marks writes: > >+static int kq = -1; > >+ int kq, rv, idx; > >kevent(0x3,0xbfbfedbc,0x1,0x0,0x0,0x0) = 0 (0x0) > >kevent(0x809abc0,0x0,0x0,0xbfbfede0,0x8,0x0) ERR#9 'Bad file descriptor' > > Look at the above 4 lines, and it is pretty clear what is going on. > You don't want to hide the global `kq' behind an uninitialised local > variable of the same name. > > Ian Woops. Thanks! -- Dominic Marks Computer & Politics Geek [work]::[npl.co.uk] << dominic.marks at npl.co.uk >> [educ]::[umist.ac.uk] << notyet-known at umist.ac.uk >> [home]::[btinternet] << dominic_marks at btinternet.com >> To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message