This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/85602] -Wsizeof-pointer-memaccess for strncat with size of source
- From: "seurer at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 19 Jun 2018 15:41:43 +0000
- Subject: [Bug middle-end/85602] -Wsizeof-pointer-memaccess for strncat with size of source
- Auto-submitted: auto-generated
- References: <bug-85602-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85602
seurer at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |seurer at gcc dot gnu.org
--- Comment #8 from seurer at gcc dot gnu.org ---
The new test cases fails in some cases:
make -k check-gcc RUNTESTFLAGS=dg.exp=c-c++-common/attr-nonstring-8.c
# of expected passes 17
# of expected passes 45
# of unexpected failures 6
FAIL: c-c++-common/attr-nonstring-8.c -std=gnu++98 (test for warnings, line
63)
FAIL: c-c++-common/attr-nonstring-8.c -std=gnu++98 (test for excess errors)
FAIL: c-c++-common/attr-nonstring-8.c -std=gnu++11 (test for warnings, line
63)
FAIL: c-c++-common/attr-nonstring-8.c -std=gnu++11 (test for excess errors)
FAIL: c-c++-common/attr-nonstring-8.c -std=gnu++14 (test for warnings, line
63)
FAIL: c-c++-common/attr-nonstring-8.c -std=gnu++14 (test for excess errors)
FAIL: c-c++-common/attr-nonstring-8.c -std=gnu++98 (test for excess errors)
Excess errors:
/home/seurer/gcc/gcc-test2/gcc/testsuite/c-c++-common/attr-nonstring-8.c:63:3:
warning: argument to 'sizeof' in 'char* strncat(char*, const char*, long
unsigned int)' call is the same expression as the source; did you mean to
provide an explicit length? [-Wsizeof-pointer-memaccess]