diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2019-02-21 20:28:49 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2019-02-22 11:20:56 -0800 |
commit | b9cc405612f6badded21cb526cdeaa627fecbb37 (patch) | |
tree | c273daae27bd0fedd5a31f7c067d28c69cc7884e /t/t4214-log-graph-octopus.sh | |
parent | tests: fix unportable "\?" and "\+" regex syntax (diff) | |
download | tgif-b9cc405612f6badded21cb526cdeaa627fecbb37.tar.xz |
commit-graph tests: fix unportable "dd" invocation
Change an unportable invocation of "dd" with count=0, that wanted to
truncate the commit-graph file. In POSIX it is unspecified what
happens when count=0 is provided[1]. The NetBSD "dd" behavior
differs from GNU (and seemingly other BSDs), which has left this test
broken since d2b86fbaa1 ("commit-graph: fix buffer read-overflow",
2019-01-15).
Copying from /dev/null would seek/truncate to seek=$zero_pos and
stop immediately after that (without being able to copy anything),
which is the right way to truncate the file.
1. http://pubs.opengroup.org/onlinepubs/9699919799/utilities/dd.html
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Helped-by: SZEDER Gábor <szeder.dev@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4214-log-graph-octopus.sh')
0 files changed, 0 insertions, 0 deletions