Handle quit message.