From owner-svn-src-all@FreeBSD.ORG Wed Apr 15 19:10:37 2009 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D7CC71065679; Wed, 15 Apr 2009 19:10:37 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C6C5C8FC14; Wed, 15 Apr 2009 19:10:37 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n3FJAb6t051985; Wed, 15 Apr 2009 19:10:37 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n3FJAboB051984; Wed, 15 Apr 2009 19:10:37 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <200904151910.n3FJAboB051984@svn.freebsd.org> From: John Baldwin Date: Wed, 15 Apr 2009 19:10:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r191113 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Apr 2009 19:10:38 -0000 Author: jhb Date: Wed Apr 15 19:10:37 2009 New Revision: 191113 URL: http://svn.freebsd.org/changeset/base/191113 Log: Update comment above _fget() for earlier change to FWRITE failures return EBADF rather than EINVAL. Submitted by: Jaakko Heinonen jh saunalahti fi MFC after: 1 month Modified: head/sys/kern/kern_descrip.c Modified: head/sys/kern/kern_descrip.c ============================================================================== --- head/sys/kern/kern_descrip.c Wed Apr 15 18:15:29 2009 (r191112) +++ head/sys/kern/kern_descrip.c Wed Apr 15 19:10:37 2009 (r191113) @@ -2027,10 +2027,8 @@ finit(struct file *fp, u_int flag, short * Extract the file pointer associated with the specified descriptor for the * current user process. * - * If the descriptor doesn't exist, EBADF is returned. - * - * If the descriptor exists but doesn't match 'flags' then return EBADF for - * read attempts and EINVAL for write attempts. + * If the descriptor doesn't exist or doesn't match 'flags', EBADF is + * returned. * * If 'hold' is set (non-zero) the file's refcount will be bumped on return. * It should be dropped with fdrop(). If it is not set, then the refcount