Hello.A quick question
Considering the fact that currentP->next may be null,isnt it dangerous to dig up currentP->next->pid.Or the while condition becomes false as soon as it hits currentP->next!=NULL?Thanks.Code:while (currentP->next!=NULL && currentP->next->pid < tempP->pid) { currentP = currentP->next; }