From owner-svn-src-head@freebsd.org Tue Apr 26 18:20:42 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 630C9B1C10C; Tue, 26 Apr 2016 18:20:42 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2E5C217B9; Tue, 26 Apr 2016 18:20:42 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u3QIKfWj094943; Tue, 26 Apr 2016 18:20:41 GMT (envelope-from cem@FreeBSD.org) Received: (from cem@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u3QIKf92094942; Tue, 26 Apr 2016 18:20:41 GMT (envelope-from cem@FreeBSD.org) Message-Id: <201604261820.u3QIKf92094942@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cem set sender to cem@FreeBSD.org using -f From: "Conrad E. Meyer" Date: Tue, 26 Apr 2016 18:20:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r298657 - head/sys/dev/sound/pci X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Apr 2016 18:20:42 -0000 Author: cem Date: Tue Apr 26 18:20:41 2016 New Revision: 298657 URL: https://svnweb.freebsd.org/changeset/base/298657 Log: emu10kx: Don't iterate beyond array bounds Reported by: Coverity CID: 1354978 Sponsored by: EMC / Isilon Storage Division Modified: head/sys/dev/sound/pci/emu10kx.c Modified: head/sys/dev/sound/pci/emu10kx.c ============================================================================== --- head/sys/dev/sound/pci/emu10kx.c Tue Apr 26 18:17:44 2016 (r298656) +++ head/sys/dev/sound/pci/emu10kx.c Tue Apr 26 18:20:41 2016 (r298657) @@ -587,7 +587,7 @@ emu_getcard(device_t dev) } } - for (i = 0; i < nitems(emu_cards); i++) { + for (i = 0; i < nitems(emu_bad_cards); i++) { if (device == emu_bad_cards[i].device) { if (subdevice == emu_bad_cards[i].subdevice) { thiscard = 0;