Re: remove duplicate code and not needed break statement
- From
Ralf Thielow <ralf.thielow@googlemail.com>
- Date
- Jul 18, 2010, 18:56 UTC
- Message-ID
- <AANLkTilU1T5ppfVZ5UXpsRXet0tcffjJ2Bi3q67wnF6L@mail.gmail.com>
- In-Reply-To
- <20100718184716.GD14367@burratino>
2010/7/18 Jonathan Nieder <jrnieder@gmail.com>:
Show 26 quoted lines
> Hi Ralf! > > Ralf Thielow wrote: > >> Remove duplicate code and not needed break statement. > > This looks like a reasonable change, with the nice effect of getting > read_pack_info_file() to almost fit in one screen. > > The commit message is not super clear. I would say: > > Subject: update-server-info: Shorten read_pack_info_file() > > The correct responses to a D and a T line in .git/objects/info/packs > are the same, so combine their case arms. In both cases we already > ‘goto’ out of the switch so while at it, remove a redundant ‘break’ > to avoid yet another line of code. > > i.e., impact in the subject line, details in the commit message body. > > It is missing a sign-off. See Documentation/SubmittingPatches for > what that means. > > Hope that helps, > Jonathan >
Thank you, this is my first patch on a mailing list using git, you see. In future I do it better and read the whole documentation before. :)
Ralf