From 9b47ff2746b74bf41d20fa43d6ed2697b0a99087 Mon Sep 17 00:00:00 2001 From: David Steele Date: Sun, 26 Jan 2020 12:29:53 -0700 Subject: [PATCH] Sort last processing queue on backup from standby. The last queue was not being sorted when a primary queue was added first. This did not affect the backup or integrity but could lead to slightly lower performance since large files were not always copied first. --- src/command/backup/backup.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/command/backup/backup.c b/src/command/backup/backup.c index 875e16a7b..b61e52ea5 100644 --- a/src/command/backup/backup.c +++ b/src/command/backup/backup.c @@ -1381,8 +1381,8 @@ backupProcessQueue(Manifest *manifest, List **queueList) THROW(FileMissingError, "no files have changed since the last backup - this seems unlikely"); // Sort the queues - for (unsigned int targetIdx = 0; targetIdx < strLstSize(targetList); targetIdx++) - lstSort(*(List **)lstGet(*queueList, targetIdx), sortOrderDesc); + for (unsigned int queueIdx = 0; queueIdx < lstSize(*queueList); queueIdx++) + lstSort(*(List **)lstGet(*queueList, queueIdx), sortOrderDesc); // Move process queues to prior context lstMove(*queueList, memContextPrior());