Re: GCC 8 warnings

2018-04-27 Thread Peter Eisentraut
On 4/24/18 05:57, Devrim Gündüz wrote: > While building stable releases and v11 on Fedora 28, I am seeing some > warnings. Attached is a patch to fix these warnings in master. These are very similar to the class of warnings we fixed last time around for GCC 7. GCC 8 is now frozen, so it would b

Re: GCC 8 warnings

2018-04-28 Thread Tom Lane
Peter Eisentraut writes: > On 4/24/18 05:57, Devrim Gündüz wrote: >> While building stable releases and v11 on Fedora 28, I am seeing some >> warnings. > Attached is a patch to fix these warnings in master. These are very > similar to the class of warnings we fixed last time around for GCC 7.

Re: GCC 8 warnings

2018-04-28 Thread Andres Freund
Hi, On 2018-04-28 12:16:39 -0400, Tom Lane wrote: > -SharedFilePath(char *path, SharedFileSet *fileset, const char *name) > +SharedFilePath(char *path, size_t size, SharedFileSet *fileset, const char > *name) > { > - chardirpath[MAXPGPATH]; > + chardirpath[MAXPGPA

Re: GCC 8 warnings

2018-06-16 Thread Tom Lane
Andres Freund writes: > On 2018-04-28 12:16:39 -0400, Tom Lane wrote: >> In the meantime, I think our response to GCC 8 should just be to >> enable -Wno-format-truncation. Certainly so in the back branches. >> There isn't one of these changes that is actually fixing a bug, >> which to me says tha

Re: GCC 8 warnings

2018-06-16 Thread Andres Freund
Hi, On 2018-06-16 13:29:55 -0400, Tom Lane wrote: > I propose the attached patch to disable these warnings if the compiler > knows the switch for them. I did not turn them off for CXX though; > anyone think there's a need to? No, not for now. I don't think it's likely that the amount of C++ wil

Re: GCC 8 warnings

2018-06-16 Thread Tom Lane
Andres Freund writes: > On 2018-06-16 13:29:55 -0400, Tom Lane wrote: >> + # Similarly disable useless truncation warnings from gcc 8+ >> + PGAC_PROG_CC_VAR_OPT(NOT_THE_CFLAGS, [-Wformat-truncation]) >> + if test -n "$NOT_THE_CFLAGS"; then >> +CFLAGS="$CFLAGS -Wno-format-truncation" >> + f

Re: GCC 8 warnings

2018-04-27 Thread Peter Eisentraut
On 4/24/18 05:57, Devrim Gündüz wrote: > While building stable releases and v11 on Fedora 28, I am seeing some > warnings. Attached is a patch to fix these warnings in master. These are very similar to the class of warnings we fixed last time around for GCC 7. GCC 8 is now frozen, so it would b

Re: GCC 8 warnings

2018-04-28 Thread Tom Lane
Peter Eisentraut writes: > On 4/24/18 05:57, Devrim Gündüz wrote: >> While building stable releases and v11 on Fedora 28, I am seeing some >> warnings. > Attached is a patch to fix these warnings in master. These are very > similar to the class of warnings we fixed last time around for GCC 7.

Re: GCC 8 warnings

2018-04-28 Thread Andres Freund
Hi, On 2018-04-28 12:16:39 -0400, Tom Lane wrote: > -SharedFilePath(char *path, SharedFileSet *fileset, const char *name) > +SharedFilePath(char *path, size_t size, SharedFileSet *fileset, const char > *name) > { > - chardirpath[MAXPGPATH]; > + chardirpath[MAXPGPA

Re: GCC 8 warnings

2018-06-16 Thread Tom Lane
Andres Freund writes: > On 2018-04-28 12:16:39 -0400, Tom Lane wrote: >> In the meantime, I think our response to GCC 8 should just be to >> enable -Wno-format-truncation. Certainly so in the back branches. >> There isn't one of these changes that is actually fixing a bug, >> which to me says tha

Re: GCC 8 warnings

2018-06-16 Thread Andres Freund
Hi, On 2018-06-16 13:29:55 -0400, Tom Lane wrote: > I propose the attached patch to disable these warnings if the compiler > knows the switch for them. I did not turn them off for CXX though; > anyone think there's a need to? No, not for now. I don't think it's likely that the amount of C++ wil

Re: GCC 8 warnings

2018-06-16 Thread Tom Lane
Andres Freund writes: > On 2018-06-16 13:29:55 -0400, Tom Lane wrote: >> + # Similarly disable useless truncation warnings from gcc 8+ >> + PGAC_PROG_CC_VAR_OPT(NOT_THE_CFLAGS, [-Wformat-truncation]) >> + if test -n "$NOT_THE_CFLAGS"; then >> +CFLAGS="$CFLAGS -Wno-format-truncation" >> + f