Re: [PATCH] name-rev: rewrite create_or_update_name()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Sep 22, 2019 at 10:18:46AM +0200, Martin Ågren wrote:
> This code was moved straight out of name_rev(). As such, we inherited
> the "goto" to jump from an if into an else-if. We also inherited the
> fact that "nothing to do -- return NULL" is handled last.

>  For the record, --color-moved confirms that your patch is a move and
>  the conversion around it looks good to me. I was a bit puzzled by what
>  the moved code actually wanted to *do* and came up with this rewrite.

Yeah, I had a bit of a "Huh?!" moment myself looking at that goto
jumping over the condition, too...  Initially I left it as-is to keep
this patch a pure code movement, and that others might have a bit of
fun as well when they stumble upon it in the future ;)

>  It seems there was some discussion around leaks and leak-plugs. That
>  would conflict/interact with this. 

And I didn't pick it up in later versions, because René's plans to
clean up memory ownership would deal with it (and with much more) as
well.




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux