From owner-cvs-src@FreeBSD.ORG Sat Nov 4 20:54:38 2006 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 933B716A40F; Sat, 4 Nov 2006 20:54:38 +0000 (UTC) (envelope-from csjp@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 64E2043D88; Sat, 4 Nov 2006 20:54:38 +0000 (GMT) (envelope-from csjp@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id kA4Kscv3047064; Sat, 4 Nov 2006 20:54:38 GMT (envelope-from csjp@repoman.freebsd.org) Received: (from csjp@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id kA4KscGZ047063; Sat, 4 Nov 2006 20:54:38 GMT (envelope-from csjp) Message-Id: <200611042054.kA4KscGZ047063@repoman.freebsd.org> From: "Christian S.J. Peron" Date: Sat, 4 Nov 2006 20:54:38 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/sys/net if_tap.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: Sat, 04 Nov 2006 20:54:38 -0000 csjp 2006-11-04 20:54:38 UTC FreeBSD src repository Modified files: sys/net if_tap.c Log: Currently, we initialize "error" to zero when it's declared, then we never initialize it to anything else. However, in the case that m_uiotombuf fails, we return error (effectively reporting success). This appears to be a relic of an older revision of this file, where "error" used to be doing something useful. (See revision 1.1, where error is used in a loop with uiomove() instead of using m_uiotomubf). So instead on unconditionally reporting success in the case there is a failure in m_uiotombuf, explicitly return ENOBUFS. While we are here, garbage collect the error variable since it's no longer required. MFC after: 2 weeks Revision Changes Path 1.65 +1 -2 src/sys/net/if_tap.c