Skip to content

Commit 35471b5

Browse files
committed
fix PTRACK backup error caused by wrong sort order
1 parent 8405a59 commit 35471b5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

catalog.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,7 @@ catalog_get_last_data_backup(parray *backup_list, TimeLineID tli)
341341
pgBackup *backup = NULL;
342342

343343
/* backup_list is sorted in order of descending ID */
344-
for (i = (int) parray_num(backup_list) - 1; i >= 0; i--)
344+
for (i = 0; i < parray_num(backup_list); i++)
345345
{
346346
backup = (pgBackup *) parray_get(backup_list, (size_t) i);
347347

0 commit comments

Comments
 (0)