From b23d8e7e174c2e68cdd3435cc42907796181d159 Mon Sep 17 00:00:00 2001 From: Aleric Inglewood Date: Sat, 23 Oct 2010 23:58:07 +0200 Subject: IMP-664: WARNING: addFeature: LLFeatureList::Attempting to add preexisting feature Disregard128DefaultDrawDistance Fix a bug that causes the last line of the feature table file to be read twice. This patch also removes the check for name.empty() because that will never be true, so might as well remove it. --- linden/indra/newview/llfeaturemanager.cpp | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'linden/indra/newview/llfeaturemanager.cpp') diff --git a/linden/indra/newview/llfeaturemanager.cpp b/linden/indra/newview/llfeaturemanager.cpp index 35613b7..54da31b 100644 --- a/linden/indra/newview/llfeaturemanager.cpp +++ b/linden/indra/newview/llfeaturemanager.cpp @@ -250,11 +250,9 @@ BOOL LLFeatureManager::loadFeatureTables() mTableVersion = version; LLFeatureList *flp = NULL; - while (!file.eof() && file.good()) + while (file >> name) { char buffer[MAX_STRING]; /*Flawfinder: ignore*/ - - file >> name; if (name.substr(0,2) == "//") { @@ -263,13 +261,6 @@ BOOL LLFeatureManager::loadFeatureTables() continue; } - if (name.empty()) - { - // This is a blank line - file.getline(buffer, MAX_STRING); - continue; - } - if (name == "list") { if (flp) -- cgit v1.1