[PATCH 1/1 linux-next] UBIFS: simplify returns

Geert Uytterhoeven geert at linux-m68k.org
Thu Mar 12 03:20:56 PDT 2015


Hi Fabian,

On Wed, Mar 11, 2015 at 6:44 PM, Fabian Frederick <fabf at skynet.be> wrote:
> @@ -1002,13 +999,9 @@ static int clean_an_unclean_leb(struct ubifs_info *c,
>
>         dbg_rcvry("LEB %d len %d", lnum, len);
>
> -       if (len == 0) {
> +       if (len == 0)
>                 /* Nothing to read, just unmap it */
> -               err = ubifs_leb_unmap(c, lnum);
> -               if (err)
> -                       return err;
> -               return 0;
> -       }
> +               return ubifs_leb_unmap(c, lnum);

While technically the curly braces are no longer needed, I'd keep them
because of the comment line.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds



More information about the linux-mtd mailing list