Any C less than 3 ms?

void deleteNode(struct ListNode* node) {

if ( node->next == NULL || node == NULL)

return;

while(true)

{

node->val = (node->next)->val;

if ( (node->next)->next == NULL)

{

node->next = NULL;

return;

}

node = node->next;

}

}