The court determines if the arrest of an individual meets with state laws.  Corrections serves to remove those convicted individuals from the society and hopefully for them to change before returning to society.