All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Sunshine <sunshine@sunshineco.com>
To: Rasmus Villemoes <rv@rasmusvillemoes.dk>
Cc: "Git List" <git@vger.kernel.org>,
	"Junio C Hamano" <gitster@pobox.com>,
	"Johannes Schindelin" <Johannes.Schindelin@gmx.de>,
	"Randall S . Becker" <randall.becker@nexbridge.ca>,
	"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Subject: Re: [PATCH] test-lib-functions.sh: update comment on generate_zero_bytes()
Date: Thu, 18 Feb 2021 12:03:55 -0500	[thread overview]
Message-ID: <CAPig+cRhvh2TpSZ-bzjiuCf-Vaf-wr1umb6EAFna3uQxU=oXyw@mail.gmail.com> (raw)
In-Reply-To: <20210218095750.939746-1-rv@rasmusvillemoes.dk>

[cc:+æver]

On Thu, Feb 18, 2021 at 7:22 AM Rasmus Villemoes <rv@rasmusvillemoes.dk> wrote:
> Commit d5cfd142ec (tests: teach the test-tool to generate NUL bytes
> and use it) changed the implementation of this helper, but didn't
> preserve the magic meaning of the word 'infinity' - in fact, since
> strtol() returns 0 when presented with that string, it ends up
> producing no output at all. Instead, the C implementation interprets
> lack of optional argument to mean infinity.
>
> Since the last and only user that actually passed 'infinity' vanished
> with d99194822b (Revert "t5562: replace /dev/zero with a pipe from
> generate_zero_bytes"), just update the comment to match the
> implementation, and while there, short-circuit "forever or X" to just
> X.

Makes sense, but note that generate_zero_bytes() is going away
entirely[1], and that the patch series which removes it is likely to
be merged to "master" soon[2].

[1]: https://lore.kernel.org/git/20210212132942.17325-5-avarab@gmail.com/
[2]: https://lore.kernel.org/git/xmqqr1legm5v.fsf@gitster.g/

      reply	other threads:[~2021-02-18 18:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-18  9:57 [PATCH] test-lib-functions.sh: update comment on generate_zero_bytes() Rasmus Villemoes
2021-02-18 17:03 ` Eric Sunshine [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAPig+cRhvh2TpSZ-bzjiuCf-Vaf-wr1umb6EAFna3uQxU=oXyw@mail.gmail.com' \
    --to=sunshine@sunshineco.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=randall.becker@nexbridge.ca \
    --cc=rv@rasmusvillemoes.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.