Some bugs in the linked list API have been fixed.