Reset the temp array so that it doesn't keep growing.