From 990c8a14046153f8ebc2036a200fa6680d18d6ad Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Sun, 29 Jan 2017 15:00:00 +0100 Subject: [PATCH] sort uid exception list in a smarter place do it closer to where it is populated. that way the debug output is sorted, and we don't sort the list if it's known to be empty. --- src/sync.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sync.c b/src/sync.c index 0a8cea6..7919981 100644 --- a/src/sync.c +++ b/src/sync.c @@ -1301,6 +1301,7 @@ box_opened2( sync_vars_t *svars, int t ) *int_array_append( &mexcs ) = srec->uid[M]; } } + sort_int_array( mexcs.array ); debugn( " exception list is:" ); for (t = 0; t < mexcs.array.size; t++) debugn( " %d", mexcs.array.data[t] ); @@ -1312,7 +1313,6 @@ box_opened2( sync_vars_t *svars, int t ) minwuid = INT_MAX; } sync_ref( svars ); - sort_int_array( mexcs.array ); load_box( svars, M, minwuid, mexcs.array ); if (!check_cancel( svars )) load_box( svars, S, (ctx[S]->opts & OPEN_OLD) ? 1 : INT_MAX, (int_array_t){ 0, 0 } );