Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 9 Jan 2009 20:41:58 +0000 (UTC)
From:      Alexander Motin <mav@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org
Subject:   svn commit: r186971 - in stable/7/sys: . contrib/pf dev/ath/ath_hal dev/cxgb netgraph
Message-ID:  <200901092041.n09KfwwJ068041@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mav
Date: Fri Jan  9 20:41:58 2009
New Revision: 186971
URL: http://svn.freebsd.org/changeset/base/186971

Log:
  MFC rev. 185183
  
  Remove unused variable.
  
  Found with:     Coverity Prevent(tm)
  CID:            3682

Modified:
  stable/7/sys/   (props changed)
  stable/7/sys/contrib/pf/   (props changed)
  stable/7/sys/dev/ath/ath_hal/   (props changed)
  stable/7/sys/dev/cxgb/   (props changed)
  stable/7/sys/netgraph/ng_socket.c

Modified: stable/7/sys/netgraph/ng_socket.c
==============================================================================
--- stable/7/sys/netgraph/ng_socket.c	Fri Jan  9 20:40:19 2009	(r186970)
+++ stable/7/sys/netgraph/ng_socket.c	Fri Jan  9 20:41:58 2009	(r186971)
@@ -259,9 +259,8 @@ ngc_send(struct socket *so, int flags, s
 	if (msg->header.typecookie == NGM_GENERIC_COOKIE &&
 	    msg->header.cmd == NGM_MKPEER) {
 		struct ngm_mkpeer *const mkp = (struct ngm_mkpeer *) msg->data;
-		struct ng_type *type;
 
-		if ((type = ng_findtype(mkp->type)) == NULL) {
+		if (ng_findtype(mkp->type) == NULL) {
 			char filename[NG_TYPESIZ + 3];
 			int fileid;
 
@@ -275,7 +274,7 @@ ngc_send(struct socket *so, int flags, s
 			}
 
 			/* See if type has been loaded successfully. */
-			if ((type = ng_findtype(mkp->type)) == NULL) {
+			if (ng_findtype(mkp->type) == NULL) {
 				free(msg, M_NETGRAPH_MSG);
 				(void)kern_kldunload(curthread, fileid,
 				    LINKER_UNLOAD_NORMAL);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200901092041.n09KfwwJ068041>