Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitdc50ba7

Browse files
committed
Move state() under backup_path initialization
1 parent366073b commitdc50ba7

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

‎pg_probackup.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ main(int argc, char *argv[])
110110
charpath[MAXPGPATH];
111111
/* Check if backup_path is directory. */
112112
structstatstat_buf;
113-
intrc=stat(backup_path,&stat_buf);
113+
intrc;
114114

115115
/* initialize configuration */
116116
pgBackup_init(&current);
@@ -164,6 +164,7 @@ main(int argc, char *argv[])
164164
elog(ERROR,"required parameter not specified: BACKUP_PATH (-B, --backup-path)");
165165
}
166166

167+
rc=stat(backup_path,&stat_buf);
167168
/* If rc == -1, there is no file or directory. So it's OK. */
168169
if (rc!=-1&& !S_ISDIR(stat_buf.st_mode))
169170
elog(ERROR,"-B, --backup-path must be a path to directory");

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp