mbox series

[0/3] some small range-diff read_patches() fixes

Message ID YRGwGDvOte/o9vkd@coredump.intra.peff.net (mailing list archive)
Headers show
Series some small range-diff read_patches() fixes | expand

Message

Jeff King Aug. 9, 2021, 10:45 p.m. UTC
Amidst all the talk of clang4 in another thread, I noticed that Debian
unstable recently shipped a clang-14 package. So I tried it out, and it
does find one small cleanup. And then looking at the surrounding code
helped me find 2 more. :)

  [1/3]: range-diff: drop useless "offset" variable from read_patches()
  [2/3]: range-diff: handle unterminated lines in read_patches()
  [3/3]: range-diff: use ssize_t for parsed "len" in read_patches()

 range-diff.c | 29 +++++++++++++----------------
 1 file changed, 13 insertions(+), 16 deletions(-)

-Peff

Comments

Derrick Stolee Aug. 10, 2021, 2:47 p.m. UTC | #1
On 8/9/2021 6:45 PM, Jeff King wrote:
> Amidst all the talk of clang4 in another thread, I noticed that Debian
> unstable recently shipped a clang-14 package. So I tried it out, and it
> does find one small cleanup. And then looking at the surrounding code
> helped me find 2 more. :)
> 
>   [1/3]: range-diff: drop useless "offset" variable from read_patches()
>   [2/3]: range-diff: handle unterminated lines in read_patches()
>   [3/3]: range-diff: use ssize_t for parsed "len" in read_patches()

I gave these a read. The code diffs are obviously correct and the
explanations are well motivated. Thanks.

-Stolee
Johannes Schindelin Aug. 14, 2021, 9:48 p.m. UTC | #2
Hi,

On Tue, 10 Aug 2021, Derrick Stolee wrote:

> On 8/9/2021 6:45 PM, Jeff King wrote:
> > Amidst all the talk of clang4 in another thread, I noticed that Debian
> > unstable recently shipped a clang-14 package. So I tried it out, and it
> > does find one small cleanup. And then looking at the surrounding code
> > helped me find 2 more. :)
> >
> >   [1/3]: range-diff: drop useless "offset" variable from read_patches()
> >   [2/3]: range-diff: handle unterminated lines in read_patches()
> >   [3/3]: range-diff: use ssize_t for parsed "len" in read_patches()
>
> I gave these a read. The code diffs are obviously correct and the
> explanations are well motivated. Thanks.

Same here. Thanks, both,
Dscho