mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-25 16:16:29 +00:00
Miscellaneous string handling cleanup
This is mainly to prevent effectively spurious truncation warnings in recent GCC versions.
This commit is contained in:
@@ -1521,10 +1521,10 @@ get_ready_archive_files(PGconn *conn, const char *data_directory)
|
||||
while ((arcdir_ent = readdir(arcdir)) != NULL)
|
||||
{
|
||||
struct stat statbuf;
|
||||
char file_path[MAXPGPATH] = "";
|
||||
char file_path[MAXPGPATH + sizeof(arcdir_ent->d_name)];
|
||||
int basenamelen = 0;
|
||||
|
||||
snprintf(file_path, MAXPGPATH,
|
||||
snprintf(file_path, sizeof(file_path),
|
||||
"%s/%s",
|
||||
archive_status_dir,
|
||||
arcdir_ent->d_name);
|
||||
|
||||
Reference in New Issue
Block a user