thread safer linked list management