lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20080108182945.GA8106@joi>
Date:	Tue, 8 Jan 2008 19:29:54 +0100
From:	Marcin Slusarz <marcin.slusarz@...il.com>
To:	Jan Kara <jack@...e.cz>
Cc:	LKML <linux-kernel@...r.kernel.org>,
	Ben Fennema <bfennema@...con.csc.calpoly.edu>,
	Christoph Hellwig <hch@...radead.org>
Subject: Re: [PATCH 4/7] udf: replace loops coded with goto to real loops

On Tue, Jan 08, 2008 at 11:17:32AM +0100, Jan Kara wrote:
> On Mon 07-01-08 22:10:01, Marcin Slusarz wrote:
> > On Mon, Jan 07, 2008 at 03:48:21PM +0100, Jan Kara wrote:
> > > On Sun 06-01-08 02:21:50, marcin.slusarz@...il.com wrote:
> > > > Signed-off-by: Marcin Slusarz <marcin.slusarz@...il.com>
> > >   I'm not sure if this improves readability in general. If the code is
> > > really a loop in nature, then we should code it using do {} while but in
> > > case we loop back just in case of some error (as seems to be the case in
> > > udf_bitmap_new_block()), then IMHO goto is more explanative. So at least
> > > that one case I'd leave as is.
> > Why do you think it's an error?
>   There is code:
> 
>           if (!udf_clear_bit(bit, bh->b_data)) {
>                 udf_debug("bit already cleared for block %d\n", bit);
>                 goto repeat;
>         }
>   Now if this happens, it's a bug AFAICS because we have been searching for
> a free block and we hold s_alloc_mutex and hence we should not race with
> any other allocation.
Fine, I'll drop this part of patch.

Marcin
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ