Skip to content

Commit 6e20f55

Browse files
committed
Merge branch 'refs/pull/291/head' into release_2_5
2 parents e2bbd4f + 7383ddd commit 6e20f55

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/pg_probackup.c

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -383,6 +383,7 @@ main(int argc, char *argv[])
383383
exit(0);
384384
}
385385

386+
/* set location based on cmdline options only */
386387
setMyLocation(backup_subcmd);
387388

388389
if (backup_path == NULL)
@@ -499,9 +500,14 @@ main(int argc, char *argv[])
499500
config_read_opt(path, instance_options, ERROR, true, true);
500501
else
501502
config_read_opt(path, instance_options, ERROR, true, false);
503+
504+
/*
505+
* We can determine our location only after reading the configuration file,
506+
* unless we are running arcive-push/archive-get - they are allowed to trust
507+
* cmdline only.
508+
*/
509+
setMyLocation(backup_subcmd);
502510
}
503-
/* Зачем второй раз устанавливать? */
504-
setMyLocation(backup_subcmd);
505511
}
506512

507513
/*

0 commit comments

Comments
 (0)