static void nodeDestruct(struct SaveNode* node)
{
    if (node->v == &node->sorted)
    {
        tr_free(node->sorted.val.l.vals);
    }
}
Referencing memory after it has been freed can cause a program to crash, use unexpected values, or execute code.