No subject



Mon Sep 29 13:31:04 2003
Return-Path: xorp-cvs-admin@icir.org
Delivery-Date: Mon, 29 Sep 2003 13:32:08 -0700
Received: from wyvern.icir.org (wyvern.icir.org [192.150.187.14])
	by tigger.icir.org (8.12.9p1/8.12.3) with ESMTP id h8TKW8fw091780
	for <atanu@tigger.icir.org>; Mon, 29 Sep 2003 13:32:08 -0700 (PDT)
	(envelope-from xorp-cvs-admin@icir.org)
Received: from fruitcake.ICSI.Berkeley.EDU (fruitcake.ICSI.Berkeley.EDU [192.150.186.11])
	by wyvern.icir.org (8.12.9p1/8.12.3) with ESMTP id h8TKW1H5043271;
	Mon, 29 Sep 2003 13:32:01 -0700 (PDT)
	(envelope-from xorp-cvs-admin@icir.org)
Received: from fruitcake.ICSI.Berkeley.EDU (localhost [127.0.0.1])
	by fruitcake.ICSI.Berkeley.EDU (8.12.9/8.12.9) with ESMTP id h8TKW1wG004312;
	Mon, 29 Sep 2003 13:32:01 -0700 (PDT)
Received: from wyvern.icir.org (wyvern.icir.org [192.150.187.14])
	by fruitcake.ICSI.Berkeley.EDU (8.12.9/8.12.9) with ESMTP id h8TKV4wG004281
	for <xorp-cvs@icsi.berkeley.edu>; Mon, 29 Sep 2003 13:31:04 -0700 (PDT)
Received: from puma.icir.org (puma.icir.org [192.150.187.73])
	by wyvern.icir.org (8.12.9p1/8.12.3) with ESMTP id h8TKV4H5043264;
	Mon, 29 Sep 2003 13:31:04 -0700 (PDT)
	(envelope-from hodson@puma.icir.org)
Received: from puma.icir.org (localhost [127.0.0.1])
	by puma.icir.org (8.12.9p1/8.12.3) with ESMTP id h8TKV4Cu090555;
	Mon, 29 Sep 2003 13:31:04 -0700 (PDT)
	(envelope-from hodson@puma.icir.org)
Message-Id: <200309292031.h8TKV4Cu090555@puma.icir.org>
X-Mailer: exmh version 2.5 07/13/2001 with nmh-1.0.3
To: Pavlin Radoslavov <pavlin@icir.org>
cc: xorp-cvs@icir.org
Subject: Re: [Xorp-cvs] XORP cvs commit: xorp/libxorp/ selector.cc 
In-Reply-To: Your message of "Mon, 29 Sep 2003 12:33:37 PDT."
             <200309291933.h8TJXbIK058445@possum.icir.org> 
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Date: Mon, 29 Sep 2003 13:31:04 -0700
From: Orion Hodson <hodson@icir.org>
Sender: xorp-cvs-admin@icir.org
Errors-To: xorp-cvs-admin@icir.org
X-BeenThere: xorp-cvs@icir.org
X-Mailman-Version: 2.0
Precedence: bulk
List-Help: <mailto:xorp-cvs-request@icir.org?subject=help>
List-Post: <mailto:xorp-cvs@icir.org>
List-Subscribe: <http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-cvs>,
	<mailto:xorp-cvs-request@icir.org?subject=subscribe>
List-Id: Mailing list for XORP CVS commit messages <xorp-cvs.icir.org>
List-Unsubscribe: <http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-cvs>,
	<mailto:xorp-cvs-request@icir.org?subject=unsubscribe>

/-- Pavlin Radoslavov wrote:
| > CVSROOT:	/usr/local/www/data/cvs
| > Module name:	xorp
| > Repository:	xorp/libxorp/
| > Changes by:	hodson@xorpc.icir.org.	03/09/29 10:58:16
| > 
| > Modified files:
| > 	xorp/libxorp/: selector.cc 
| > 
| > Log message:
| > 	Remove EINTR handling around select call.  We'll see EINTR after a
| > 	signal handler has been invoked.  Say we want the signal handler to
| > 	clean up and exit, then the existing code gave a non-deterministic
| > 	opportunity to do so.  In an idle eventloop we'd typically be calling
| > 	select with a timeout of zero, get an EINTR, and because of the goto
| > 	do select again with a timeout of zero.  Unless the signal handler
| > 	calls exit() we're potentially blocked forever here.
| 
| Are you sure we want to completely ignore EINTR?

IMHO, there are no errors we want to ignore arising from the SelectorList's 
select(2) invocation.  Apparent annoyance stems from the fact that comments 
were made at the time about the special case EINTR handling and the code 
remained untouched.

| I appreciate that you found and fixed the select() restarting
| problem, 
| but now when I press Ctrl-C, there is a "select failed"
| error message that is not needed:
| 
| pavlin@possum[532] ./xorp_finder 
| ^CSIGINT received. Exiting.
| [ 2003/09/29 12:25:56  ERROR xorp_finder:58186 LIBXORP +228 selector.cc selec
| t ] SelectorList::select failed: Interrupted system call
| 
| The solution for this is just not to print XLOG_ERROR() in case of
| EINTR (see patch below).

The error message tells signal generator that the process was blocked before the interrupt was received, ie they can see the process was wedged somewhere.  For the rare occasions this information might be useful I'd be inclined to leave things as they are.

Kind Regards
- Orion



_______________________________________________
Xorp-cvs mailing list
Xorp-cvs@icir.org
http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-cvs