Re: [PATCH 1/2] config.mak.dev: workaround gcc 12 bug affecting "pedantic" CI job
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Apr 15, 2022, 23:56 UTC
- Message-ID
- <xmqqbkx1aojp.fsf@gitster.g>
- In-Reply-To
- <20220415231342.35980-2-carenas@gmail.com>
Carlo Marcelo Arenas Belón <carenas@gmail.com> writes:
Show 7 quoted lines
> Originally noticed by Peff[1], but yet to be corrected[2] and planned to > be released with Fedora 36 (scheduled for Apr 19). > > dir.c: In function ‘git_url_basename’: > dir.c:3085:13: error: ‘memchr’ specified bound [9223372036854775808, 0] exceeds maximum object size 9223372036854775807 [-Werror=stringop-overread] > 3085 | if (memchr(start, '/', end - start) == NULL > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
I've seen this one; is this accepted on their side that the compiler is hurting us with a false positive here?
> +# https://bugzilla.redhat.com/show_bug.cgi?id=2075786 > +ifneq ($(filter gcc12,$(COMPILER_FEATURES)),) > +DEVELOPER_CFLAGS += -Wno-error=stringop-overread > +endif
If this does not break the build further, and it makes the -Werror build succeed, I wouldn't be too much worried. I think this one and the other one are innocuous enough that they can be fast-tracked.
Thanks.