From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#10044: "warning: reader_thread.SetEvent failed with 6 for fd -1" and accessing fd_info[-1] Date: Mon, 14 Nov 2011 19:14:21 +0200 Message-ID: <83vcqmeidu.fsf@gnu.org> References: Reply-To: Eli Zaretskii NNTP-Posting-Host: lo.gmane.org X-Trace: dough.gmane.org 1321290997 15324 80.91.229.12 (14 Nov 2011 17:16:37 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 14 Nov 2011 17:16:37 +0000 (UTC) Cc: 10044@debbugs.gnu.org To: Juanma Barranquero Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Nov 14 18:16:33 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RQ092-0002jJ-GT for geb-bug-gnu-emacs@m.gmane.org; Mon, 14 Nov 2011 18:16:32 +0100 Original-Received: from localhost ([::1]:52583 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RQ091-0006jy-Ks for geb-bug-gnu-emacs@m.gmane.org; Mon, 14 Nov 2011 12:16:31 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:45608) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RQ08y-0006jS-St for bug-gnu-emacs@gnu.org; Mon, 14 Nov 2011 12:16:30 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RQ08y-0005bg-0p for bug-gnu-emacs@gnu.org; Mon, 14 Nov 2011 12:16:28 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:47832) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RQ08x-0005bc-Vc for bug-gnu-emacs@gnu.org; Mon, 14 Nov 2011 12:16:27 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1RQ09W-00079S-9m for bug-gnu-emacs@gnu.org; Mon, 14 Nov 2011 12:17:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 14 Nov 2011 17:17:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 10044 X-GNU-PR-Package: emacs,w32 X-GNU-PR-Keywords: Original-Received: via spool by 10044-submit@debbugs.gnu.org id=B10044.132129101827477 (code B ref 10044); Mon, 14 Nov 2011 17:17:02 +0000 Original-Received: (at 10044) by debbugs.gnu.org; 14 Nov 2011 17:16:58 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RQ09S-000798-HQ for submit@debbugs.gnu.org; Mon, 14 Nov 2011 12:16:58 -0500 Original-Received: from mtaout23.012.net.il ([80.179.55.175]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RQ09Q-00078w-Dt for 10044@debbugs.gnu.org; Mon, 14 Nov 2011 12:16:57 -0500 Original-Received: from conversion-daemon.a-mtaout23.012.net.il by a-mtaout23.012.net.il (HyperSendmail v2007.08) id <0LUN00000UDJCG00@a-mtaout23.012.net.il> for 10044@debbugs.gnu.org; Mon, 14 Nov 2011 19:16:15 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([77.124.184.15]) by a-mtaout23.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0LUN000TBUN22U80@a-mtaout23.012.net.il>; Mon, 14 Nov 2011 19:16:15 +0200 (IST) In-reply-to: X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Mon, 14 Nov 2011 12:17:02 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:53900 Archived-At: > From: Juanma Barranquero > Date: Mon, 14 Nov 2011 16:33:42 +0100 > > which means that cp->fd is being used as an index into fd_info[], and > the choice between _sys_wait_accept and _sys_read_ahead is bogus. > > IIUC, cp->fd == -1 means that the wait was intended, but no input is > expected, so I think the following patch is enough: > > > === modified file 'src/w32proc.c' > --- src/w32proc.c 2011-06-24 21:25:22 +0000 > +++ src/w32proc.c 2011-11-14 15:19:09 +0000 > @@ -241,7 +241,8 @@ > > /* We have to wait for the go-ahead before we can start */ > if (cp == NULL > - || WaitForSingleObject (cp->char_consumed, INFINITE) != WAIT_OBJECT_0) > + || WaitForSingleObject (cp->char_consumed, INFINITE) != WAIT_OBJECT_0 > + || cp->fd < 0) > return 1; > > for (;;) Let's go for it, thanks. Does this patch by chance solve a similar bogus DebPrint message each time a versioned file under bzr control is visited?