[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: coreutils-9.4.170-7b206 undefined behaviour in tests
From: |
Sam James |
Subject: |
Re: coreutils-9.4.170-7b206 undefined behaviour in tests |
Date: |
Sun, 24 Mar 2024 15:39:18 +0000 |
User-agent: |
mu4e 1.12.2; emacs 30.0.50 |
Bruno Haible <bruno@clisp.org> writes:
> Hi,
>
> Building coreutils-9.4.170-7b206 on a glibc system, with clang and ASAN and
> UBSAN options, produces 4 test failures.
>
> I'm using clang 17.0.4 with the options
> CC="$CC
> -fsanitize=address,undefined,signed-integer-overflow,shift,integer-divide-by-zero"
> CFLAGS="-O0 -fno-omit-frame-pointer -ggdb"
> ASAN_OPTIONS="detect_leaks=0 abort_on_error=1 allocator_may_return_null=1"
>
> The failing tests are:
>
> FAIL: tests/misc/comm.pl
> FAIL: tests/join/join.pl
> FAIL: tests/uniq/uniq.pl
> FAIL: tests/ls/removed-directory.sh
>
> In the test-suite.log file there are hundreds of occurrences of
>
> + ../lib/linebuffer.c:65:22: runtime error: applying zero offset to null
> pointer
> + SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior
> ../lib/linebuffer.c:65:22 in
>
> and 1 occurrence of
>
> +../lib/mpsort.c:155:34: runtime error: applying zero offset to null pointer
> +SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior
> ../lib/mpsort.c:155:34 in
>
> I have proposed a fix for this in
> <https://lists.gnu.org/archive/html/bug-gnulib/2023-12/msg00055.html>,
> but Paul Eggert opposes it.
That's a shame. I was planning on doing an UBSAN run again over GNU
packages and it'll be a pain to have to keep adjusting for this.
>
> Bruno
- new snapshot available: coreutils-9.4.170-7b206.tar.xz, Pádraig Brady, 2024/03/23
- Re: new snapshot available: coreutils-9.4.170-7b206.tar.xz, Sam James, 2024/03/23
- coreutils-9.4.170-7b206 undefined behaviour in tests, Bruno Haible, 2024/03/24
- coreutils-9.4.170-7b206 FTBFS on AIX 7.3.1, Bruno Haible, 2024/03/24
- coreutils-9.4.170-7b206 help/help-version test failure, Bruno Haible, 2024/03/24
- coreutils-9.4.170-7b206 uniq/uniq test failure, Bruno Haible, 2024/03/24