From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1761300AbXGXMcy (ORCPT ); Tue, 24 Jul 2007 08:32:54 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754078AbXGXMcq (ORCPT ); Tue, 24 Jul 2007 08:32:46 -0400 Received: from mx1.suse.de ([195.135.220.2]:52101 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753888AbXGXMcp (ORCPT ); Tue, 24 Jul 2007 08:32:45 -0400 Date: Tue, 24 Jul 2007 14:32:44 +0200 Message-ID: From: Takashi Iwai To: Adrian Bunk Cc: perex@suse.cz, linux-kernel@vger.kernel.org Subject: Re: [2.6 patch] sound/pci/cs46xx/: fix an off-by-one In-Reply-To: <20070723145116.GL26212@stusta.de> References: <20070723145116.GL26212@stusta.de> User-Agent: Wanderlust/2.15.5 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.7 (=?ISO-8859-4?Q?Sanj=F2?=) APEL/10.6 MULE XEmacs/21.5 (beta27) (fiddleheads) (+CVS-20060704) (i386-suse-linux) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org At Mon, 23 Jul 2007 16:51:16 +0200, Adrian Bunk wrote: > > This patch fixes an off-by-one in a snd_assert() spotted by the > Coverity checker. > > Signed-off-by: Adrian Bunk Applied it to ALSA tree. Thanks. Takashi > > --- > --- linux-2.6.22-rc6-mm1/sound/pci/cs46xx/dsp_spos_scb_lib.c.old 2007-07-23 15:33:17.000000000 +0200 > +++ linux-2.6.22-rc6-mm1/sound/pci/cs46xx/dsp_spos_scb_lib.c 2007-07-23 15:33:37.000000000 +0200 > @@ -1480,7 +1480,7 @@ void cs46xx_dsp_destroy_pcm_channel (str > if (!pcm_channel->src_scb->ref_count) { > cs46xx_dsp_remove_scb(chip,pcm_channel->src_scb); > > - snd_assert (pcm_channel->src_slot >= 0 && pcm_channel->src_slot <= DSP_MAX_SRC_NR, > + snd_assert (pcm_channel->src_slot >= 0 && pcm_channel->src_slot < DSP_MAX_SRC_NR, > return ); > > ins->src_scb_slots[pcm_channel->src_slot] = 0; > > - > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > Please read the FAQ at http://www.tux.org/lkml/ >