mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
Fix new warnings from GCC 7
This addresses the new warning types -Wformat-truncation -Wformat-overflow that are part of -Wall, via -Wformat, in GCC 7.
This commit is contained in:
@ -41,7 +41,7 @@ char *additional_ext = NULL; /* Extension to remove from filenames */
|
||||
|
||||
char *archiveLocation; /* where to find the archive? */
|
||||
char *restartWALFileName; /* the file from which we can restart restore */
|
||||
char WALFilePath[MAXPGPATH]; /* the file path including archive */
|
||||
char WALFilePath[MAXPGPATH * 2]; /* the file path including archive */
|
||||
char exclusiveCleanupFileName[MAXPGPATH]; /* the oldest file we
|
||||
* want to remain in
|
||||
* archive */
|
||||
@ -144,7 +144,7 @@ CleanupPriorWALFiles(void)
|
||||
* extension that might have been chopped off before testing
|
||||
* the sequence.
|
||||
*/
|
||||
snprintf(WALFilePath, MAXPGPATH, "%s/%s",
|
||||
snprintf(WALFilePath, sizeof(WALFilePath), "%s/%s",
|
||||
archiveLocation, xlde->d_name);
|
||||
|
||||
if (dryrun)
|
||||
|
Reference in New Issue
Block a user