[runtime] Properly unlink a node in the tls slot freelist. Fixes #17290.

The existing search code would not update the previous pointer so we would be
always unlinking all nodes in the freelist in front of the one picked.