Uses build in list max function in thread.c.