From owner-cvs-src@FreeBSD.ORG Wed Nov 22 17:21:29 2006 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AA72016A416; Wed, 22 Nov 2006 17:21:29 +0000 (UTC) (envelope-from sam@errno.com) Received: from ebb.errno.com (ebb.errno.com [69.12.149.25]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1D7D343D55; Wed, 22 Nov 2006 17:20:46 +0000 (GMT) (envelope-from sam@errno.com) Received: from [10.0.0.248] (trouble.errno.com [10.0.0.248]) (authenticated bits=0) by ebb.errno.com (8.13.6/8.12.6) with ESMTP id kAMHLEsR067013 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 22 Nov 2006 09:21:15 -0800 (PST) (envelope-from sam@errno.com) Message-ID: <4564870A.2030705@errno.com> Date: Wed, 22 Nov 2006 09:21:14 -0800 From: Sam Leffler User-Agent: Thunderbird 1.5.0.7 (X11/20060920) MIME-Version: 1.0 To: src-committers@FreeBSD.org References: <200611221716.kAMHGsmY013192@repoman.freebsd.org> In-Reply-To: <200611221716.kAMHGsmY013192@repoman.freebsd.org> X-Enigmail-Version: 0.94.0.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/netinet tcp_usrreq.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Nov 2006 17:21:29 -0000 Sam Leffler wrote: > sam 2006-11-22 17:16:54 UTC > > FreeBSD src repository > > Modified files: > sys/netinet tcp_usrreq.c > Log: > Change error codes returned by protocol operations when an inpcb is > marked INP_DROPPED or INP_TIMEWAIT: > o return ECONNRESET instead of EINVAL for close, disconnect, shutdown, > rcvd, rcvoob, and send operations > o return ECONNABORTED instead of EINVAL for accept > > These changes should reduce confusion in applications since EINVAL is > normally interpreted to mean an invalid file descriptor. This change > does not conflict with POSIX or other standards I checked. The return > of EINVAL has always been possible but rare; it's become more common > with recent changes to the socket/inpcb handling and with finer-grained > locking and preemption. > > Note: there are other instances of EINVAL for this state that were > left unchanged; they should be reviewed. > > Reviewed by: rwatson, andre, ru > MFC after: 1 month Note I intentionally didn't change the manual pages. I'll wait for any discussion/refinement to settle before doing that. Sam