@@ -360,14 +360,14 @@ set_min_recovery_point(pgFile *file, const char *backup_path,
360360 * Copy pg_control file to backup. We do not apply compression to this file.
361361 */
362362void
363- copy_pgcontrol_file (const char * from_root ,const char * to_root ,pgFile * file , fio_location location )
363+ copy_pgcontrol_file (const char * from_root ,fio_location from_location , const char * to_root ,fio_location to_location , pgFile * file )
364364{
365365ControlFileData ControlFile ;
366366char * buffer ;
367367size_t size ;
368368char to_path [MAXPGPATH ];
369369
370- buffer = slurpFile (from_root ,XLOG_CONTROL_FILE ,& size , false,FIO_DB_HOST );
370+ buffer = slurpFile (from_root ,XLOG_CONTROL_FILE ,& size , false,from_location );
371371
372372digestControlFile (& ControlFile ,buffer ,size );
373373
@@ -376,7 +376,7 @@ copy_pgcontrol_file(const char *from_root, const char *to_root, pgFile *file, fi
376376file -> write_size = size ;
377377
378378join_path_components (to_path ,to_root ,file -> path + strlen (from_root )+ 1 );
379- writeControlFile (& ControlFile ,to_path ,location );
379+ writeControlFile (& ControlFile ,to_path ,to_location );
380380
381381pg_free (buffer );
382382}