[Bug tree-optimization/88835] overly aggressive -Werror=format-overflow for printf since r265648
mark at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sat Feb 9 11:22:00 GMT 2019
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88835
--- Comment #7 from Mark Wielaard <mark at gcc dot gnu.org> ---
Is this a regression that will probably be fixed for GCC 9.1 or should we be
adding workaround to the code.
Currently elfutils won't build on distros that started using the GCC 9.0
prerelease on 32bit architectures (i686, arm32):
BUILDSTDERR: readelf.c: In function 'print_debug_str_section':
BUILDSTDERR: readelf.c:10152:15: error: '%*llx' directive output between 4 and
2147483647 bytes may cause result to exceed 'INT_MAX'
[-Werror=format-overflow=]
BUILDSTDERR: 10152 | printf (" [%*" PRIx64 "] \"%s\"\n", digits,
(uint64_t) offset, str);
BUILDSTDERR: | ^~~~~~
BUILDSTDERR: readelf.c:10152:18: note: format string is defined here
BUILDSTDERR: 10152 | printf (" [%*" PRIx64 "] \"%s\"\n", digits,
(uint64_t) offset, str);
BUILDSTDERR: readelf.c:10152:15: note: directive argument in the range [0,
18446744073709551614]
BUILDSTDERR: 10152 | printf (" [%*" PRIx64 "] \"%s\"\n", digits,
(uint64_t) offset, str);
BUILDSTDERR: |
More information about the Gcc-bugs
mailing list