@@ -492,7 +492,7 @@ do_backup_instance(void)
492
492
current .data_bytes = 0 ;
493
493
494
494
/* Obtain current timeline */
495
- if (instance_config . remote . enabled )
495
+ if (IsReplicationProtocol () )
496
496
{
497
497
char * sysidentifier ;
498
498
TimeLineID starttli ;
@@ -632,7 +632,8 @@ do_backup_instance(void)
632
632
backup_files_list = parray_new ();
633
633
634
634
/* list files with the logical path. omit $PGDATA */
635
- if (instance_config .remote .enabled )
635
+
636
+ if (IsReplicationProtocol ())
636
637
get_remote_pgdata_filelist (backup_files_list );
637
638
else
638
639
dir_list_file (backup_files_list , instance_config .pgdata ,
@@ -699,7 +700,7 @@ do_backup_instance(void)
699
700
char * dir_name ;
700
701
char database_path [MAXPGPATH ];
701
702
702
- if (!instance_config . remote . enabled )
703
+ if (!IsReplicationProtocol () )
703
704
dir_name = GetRelativePath (file -> path , instance_config .pgdata );
704
705
else
705
706
dir_name = file -> path ;
@@ -749,7 +750,7 @@ do_backup_instance(void)
749
750
750
751
elog (VERBOSE , "Start thread num: %i" , i );
751
752
752
- if (!instance_config . remote . enabled )
753
+ if (!IsReplicationProtocol () )
753
754
pthread_create (& threads [i ], NULL , backup_files , arg );
754
755
else
755
756
pthread_create (& threads [i ], NULL , remote_backup_files , arg );
@@ -902,7 +903,7 @@ do_backup(time_t start_time)
902
903
check_server_version ();
903
904
904
905
/* TODO fix it for remote backup*/
905
- if (!instance_config . remote . enabled )
906
+ if (!IsReplicationProtocol () )
906
907
current .checksum_version = get_data_checksum_version (true);
907
908
908
909
is_checksum_enabled = pg_checksum_enable ();
@@ -958,7 +959,7 @@ do_backup(time_t start_time)
958
959
* belogns to the same instance.
959
960
*/
960
961
/* TODO fix it for remote backup */
961
- if (!instance_config . remote . enabled )
962
+ if (!IsReplicationProtocol () )
962
963
check_system_identifiers ();
963
964
964
965
0 commit comments