Skip to content

Commit 5f419c3

Browse files
committed
remove_temp_wal_file: accept raw interface instead of pointer.
1 parent fed7014 commit 5f419c3

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/archive.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -359,9 +359,9 @@ push_file(WALSegno *xlogfile, const char *archive_status_dir,
359359
}
360360

361361
static void
362-
remove_temp_wal_file(pioDrive_i *backup_drive, char *partpath)
362+
remove_temp_wal_file(pioDrive_i backup_drive, char *partpath)
363363
{
364-
err_i remerr = $i(pioRemove, *backup_drive, partpath, false);
364+
err_i remerr = $i(pioRemove, backup_drive, partpath, false);
365365
if ($haserr(remerr))
366366
elog(WARNING, "Temp WAL: %s", $errmsg(remerr));
367367
}
@@ -527,7 +527,7 @@ push_file_internal(const char *wal_file_name, const char *pg_xlog_dir,
527527
"checksum, skip pushing: \"%s\"", from_fullpath);
528528
$i(pioClose, in);
529529
$i(pioClose, out);
530-
remove_temp_wal_file(&backup_drive, to_fullpath_part);
530+
remove_temp_wal_file(backup_drive, to_fullpath_part);
531531
return 1;
532532
}
533533
else if (overwrite)
@@ -540,7 +540,7 @@ push_file_internal(const char *wal_file_name, const char *pg_xlog_dir,
540540
{
541541
$i(pioClose, in);
542542
$i(pioClose, out);
543-
remove_temp_wal_file(&backup_drive, to_fullpath_part);
543+
remove_temp_wal_file(backup_drive, to_fullpath_part);
544544

545545
elog(ERROR, "WAL file already exists in archive with "
546546
"different checksum: \"%s\"", to_fullpath);
@@ -575,22 +575,22 @@ push_file_internal(const char *wal_file_name, const char *pg_xlog_dir,
575575
if ($haserr(err))
576576
{
577577
$i(pioClose, out);
578-
remove_temp_wal_file(&backup_drive, to_fullpath_part);
578+
remove_temp_wal_file(backup_drive, to_fullpath_part);
579579
elog(ERROR, "Copy WAL: %s", $errmsg(err));
580580
}
581581

582582
err = $i(pioClose, out, .sync = !no_sync);
583583
if ($haserr(err))
584584
{
585-
remove_temp_wal_file(&backup_drive, to_fullpath_part);
585+
remove_temp_wal_file(backup_drive, to_fullpath_part);
586586
elog(ERROR, "Temp WAL: %s", $errmsg(err));
587587
}
588588

589589
/* Rename temp file to destination file */
590590
err = $i(pioRename, backup_drive, to_fullpath_part, to_fullpath);
591591
if ($haserr(err))
592592
{
593-
remove_temp_wal_file(&backup_drive, to_fullpath_part);
593+
remove_temp_wal_file(backup_drive, to_fullpath_part);
594594
elog(ERROR, "%s", $errmsg(err));
595595
}
596596

0 commit comments

Comments
 (0)