@@ -492,7 +492,7 @@ do_backup_instance(void)
492492current .data_bytes = 0 ;
493493
494494/* Obtain current timeline */
495- if (instance_config . remote . enabled )
495+ if (IsReplicationProtocol () )
496496{
497497char * sysidentifier ;
498498TimeLineID starttli ;
@@ -632,7 +632,8 @@ do_backup_instance(void)
632632backup_files_list = parray_new ();
633633
634634/* list files with the logical path. omit $PGDATA */
635- if (instance_config .remote .enabled )
635+
636+ if (IsReplicationProtocol ())
636637get_remote_pgdata_filelist (backup_files_list );
637638else
638639dir_list_file (backup_files_list ,instance_config .pgdata ,
@@ -699,7 +700,7 @@ do_backup_instance(void)
699700char * dir_name ;
700701char database_path [MAXPGPATH ];
701702
702- if (!instance_config . remote . enabled )
703+ if (!IsReplicationProtocol () )
703704dir_name = GetRelativePath (file -> path ,instance_config .pgdata );
704705else
705706dir_name = file -> path ;
@@ -749,7 +750,7 @@ do_backup_instance(void)
749750
750751elog (VERBOSE ,"Start thread num: %i" ,i );
751752
752- if (!instance_config . remote . enabled )
753+ if (!IsReplicationProtocol () )
753754pthread_create (& threads [i ],NULL ,backup_files ,arg );
754755else
755756pthread_create (& threads [i ],NULL ,remote_backup_files ,arg );
@@ -902,7 +903,7 @@ do_backup(time_t start_time)
902903check_server_version ();
903904
904905/* TODO fix it for remote backup*/
905- if (!instance_config . remote . enabled )
906+ if (!IsReplicationProtocol () )
906907current .checksum_version = get_data_checksum_version (true);
907908
908909is_checksum_enabled = pg_checksum_enable ();
@@ -958,7 +959,7 @@ do_backup(time_t start_time)
958959 * belogns to the same instance.
959960 */
960961/* TODO fix it for remote backup */
961- if (!instance_config . remote . enabled )
962+ if (!IsReplicationProtocol () )
962963check_system_identifiers ();
963964
964965