while ( (list = list->next) )
struct PIDList* getRecordForPID(struct PIDList* list, pid_t pid) { while(list = list->next) if (list->pid == pid) return list; return NULL; }