Date: Tue, 12 Dec 2006 13:41:29 +0100 From: Bernd Walter <ticso@cicely12.cicely.de> To: Warner Losh <imp@freebsd.org> Cc: Perforce Change Reviews <perforce@freebsd.org> Subject: Re: PERFORCE change 111526 for review Message-ID: <20061212124128.GS54209@cicely12.cicely.de> In-Reply-To: <200612120328.kBC3SVQX086559@repoman.freebsd.org> References: <200612120328.kBC3SVQX086559@repoman.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Dec 12, 2006 at 03:28:31AM +0000, Warner Losh wrote: > http://perforce.freebsd.org/chv.cgi?CH=111526 > > Change 111526 by imp@imp_lighthouse on 2006/12/12 03:27:31 > > Don't leak a lock on an invalid transfer. Ups... > Affected files ... > > .. //depot/projects/arm/src/sys/arm/at91/at91_twi.c#39 edit > > Differences ... > > ==== //depot/projects/arm/src/sys/arm/at91/at91_twi.c#39 (text+ko) ==== > > @@ -321,8 +321,10 @@ > len = msgs[i].len; > buf = msgs[i].buf; > /* zero byte transfers aren't allowed */ > - if (len == 0 || buf == NULL) > - return (EINVAL); > + if (len == 0 || buf == NULL) { > + err = EINVAL; > + goto out; > + } > if (len == 1) > WR4(sc, TWI_CR, TWI_CR_START | TWI_CR_STOP); > else -- B.Walter http://www.bwct.de http://www.fizon.de bernd@bwct.de info@bwct.de support@fizon.de
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061212124128.GS54209>