svn commit: r338161 - head/sys/dev/cxgbe/tom

Navdeep Parhar np at FreeBSD.org
Tue Aug 21 22:19:35 UTC 2018


Author: np
Date: Tue Aug 21 22:19:34 2018
New Revision: 338161
URL: https://svnweb.freebsd.org/changeset/base/338161

Log:
  cxgbe/tom: Make sure 'matched' is always initialized before use.
  
  Reported by:	Coverity (CID 1390894)
  MFC after:	1 week
  Sponsored by:	Chelsio Communications

Modified:
  head/sys/dev/cxgbe/tom/t4_tom.c

Modified: head/sys/dev/cxgbe/tom/t4_tom.c
==============================================================================
--- head/sys/dev/cxgbe/tom/t4_tom.c	Tue Aug 21 22:15:57 2018	(r338160)
+++ head/sys/dev/cxgbe/tom/t4_tom.c	Tue Aug 21 22:19:34 2018	(r338161)
@@ -1269,6 +1269,7 @@ lookup_offload_policy(struct adapter *sc, int open_typ
 	if (pkt == NULL || pktlen == 0 || buflen == 0)
 		return (&disallow_offloading_settings);
 
+	matched = 0;
 	r = &op->rule[0];
 	for (i = 0; i < op->nrules; i++, r++) {
 		if (r->open_type != open_type &&


More information about the svn-src-head mailing list