* src/cache/ftcmru.c (FTC_MruList_RemoveSelection): Purge backwards.

This commit is contained in:
Alexei Podtelezhnikov 2023-05-03 23:33:32 -04:00
parent f2f9754542
commit 345f88109b
1 changed files with 5 additions and 5 deletions

10
src/cache/ftcmru.c vendored
View File

@ -330,22 +330,22 @@
FT_Pointer key )
{
FTC_MruNode first = list->nodes;
FTC_MruNode node, next;
FTC_MruNode prev, node;
if ( !first || !selection )
return;
next = first;
prev = first->prev;
do
{
node = next;
next = node->next;
node = prev;
prev = node->prev;
if ( selection( node, key ) )
FTC_MruList_Remove( list, node );
} while ( next != first );
} while ( node != first );
}