From 1f101ee2a3494565275deac8ab63a1a4c6512eb0 Mon Sep 17 00:00:00 2001 From: Roxie Linden Date: Thu, 27 May 2010 11:52:39 -0700 Subject: EXT-7388 - --grid command-line argument does nothing QAR-3119 --grid command-line argument does nothing Made --grid specifier case insensitive. Fixed some issues with specifying non-well-known-grids Fixed some issues with specifying --loginuri, --loginpage and --helperuri --- indra/newview/llviewernetwork.cpp | 177 ++++++++++++++++++++------------------ 1 file changed, 93 insertions(+), 84 deletions(-) (limited to 'indra/newview/llviewernetwork.cpp') diff --git a/indra/newview/llviewernetwork.cpp b/indra/newview/llviewernetwork.cpp index c76eee80f7..619deaf50b 100644 --- a/indra/newview/llviewernetwork.cpp +++ b/indra/newview/llviewernetwork.cpp @@ -226,11 +226,11 @@ void LLGridManager::initialize(const std::string& grid_file) LLSD grid = grid_itr->second; // TODO: Make sure gridfile specified label is not // a system grid label - LL_INFOS("GridManager") << "reading: " << key_name << LL_ENDL; + LL_DEBUGS("GridManager") << "reading: " << key_name << LL_ENDL; if (mGridList.has(key_name) && mGridList[key_name].has(GRID_IS_SYSTEM_GRID_VALUE)) { - LL_INFOS("GridManager") << "Cannot override grid " << key_name << " as it's a system grid" << LL_ENDL; + LL_DEBUGS("GridManager") << "Cannot override grid " << key_name << " as it's a system grid" << LL_ENDL; // If the system grid does exist in the grids file, and it's marked as a favorite, set it as a favorite. if(grid_itr->second.has(GRID_IS_FAVORITE_VALUE) && grid_itr->second[GRID_IS_FAVORITE_VALUE].asBoolean() ) { @@ -242,7 +242,7 @@ void LLGridManager::initialize(const std::string& grid_file) try { addGrid(grid); - LL_INFOS("GridManager") << "Added grid: " << key_name << LL_ENDL; + LL_DEBUGS("GridManager") << "Added grid: " << key_name << LL_ENDL; } catch (...) { @@ -260,84 +260,90 @@ void LLGridManager::initialize(const std::string& grid_file) std::string cmd_line_grid = gSavedSettings.getString("CmdLineGridChoice"); if(!cmd_line_grid.empty()) { + // try to find the grid assuming the command line parameter is + // the case-insensitive 'label' of the grid. ie 'Agni' mGrid = getGridByLabel(cmd_line_grid); + if(mGrid.empty()) + { + // if we couldn't find it, assume the + // requested grid is the actual grid 'name' or index, + // which would be the dns name of the grid (for non + // linden hosted grids) + // If the grid isn't there, that's ok, as it will be + // automatically added later. + mGrid = cmd_line_grid; + } + + } + else + { + // if a grid was not passed in via the command line, grab it from the CurrentGrid setting. + // if there's no current grid, that's ok as it'll be either set by the value passed + // in via the login uri if that's specified, or will default to maingrid + mGrid = gSavedSettings.getString("CurrentGrid"); + } + + if(mGrid.empty()) + { + // no grid was specified so default to maingrid + LL_DEBUGS("GridManager") << "Setting grid to MAINGRID as no grid has been specified " << LL_ENDL; + mGrid = MAINGRID; + + } + + // generate a 'grid list' entry for any command line parameter overrides + // or setting overides that we'll add to the grid list or override + // any grid list entries with. + LLSD grid = LLSD::emptyMap(); + + bool grid_dirty = false; + if(mGridList.has(mGrid)) + { + grid = mGridList[mGrid]; + } + else + { + grid[GRID_VALUE] = mGrid; + grid_dirty = true; } - LL_INFOS("GridManager") << "Grid Name: " << mGrid << LL_ENDL; - // If a command line login URI was passed in, so we should add the command - // line grid to the list of grids - LLSD cmd_line_login_uri = gSavedSettings.getLLSD("CmdLineLoginURI"); if (cmd_line_login_uri.isString()) { - LL_INFOS("GridManager") << "adding cmd line login uri" << LL_ENDL; - // grab the other related URI values - std::string cmd_line_helper_uri = gSavedSettings.getString("CmdLineHelperURI"); - std::string cmd_line_login_page = gSavedSettings.getString("LoginPage"); - - // we've a cmd line login, so add a grid for the command line, - // overwriting any existing grids - LLSD grid = LLSD::emptyMap(); + grid_dirty = true; grid[GRID_LOGIN_URI_VALUE] = LLSD::emptyArray(); grid[GRID_LOGIN_URI_VALUE].append(cmd_line_login_uri); - LL_INFOS("GridManager") << "cmd line login uri: " << cmd_line_login_uri.asString() << LL_ENDL; - LLURI uri(cmd_line_login_uri.asString()); - if (mGrid.empty()) - { - // if a grid name was not passed in via the command line, - // then set the grid name based on the hostname of the - // login uri - mGrid = uri.hostName(); - } - - grid[GRID_VALUE] = mGrid; - - if (mGridList.has(mGrid) && mGridList[mGrid].has(GRID_LABEL_VALUE)) - { - grid[GRID_LABEL_VALUE] = mGridList[mGrid][GRID_LABEL_VALUE]; - } - else - { - grid[GRID_LABEL_VALUE] = mGrid; - } - if(!cmd_line_helper_uri.empty()) - { - grid[GRID_HELPER_URI_VALUE] = cmd_line_helper_uri; - } - - if(!cmd_line_login_page.empty()) - { - grid[GRID_LOGIN_PAGE_VALUE] = cmd_line_login_page; - } - // if the login page, helper URI value, and so on are not specified, - // add grid will generate them. - - // Also, we will override a system grid if values are passed in via the command - // line, for testing. These values will not be remembered though. - if (mGridList.has(mGrid) && mGridList[mGrid].has(GRID_IS_SYSTEM_GRID_VALUE)) - { - grid[GRID_IS_SYSTEM_GRID_VALUE] = TRUE; - } - addGrid(grid); } - // if a grid was not passed in via the command line, grab it from the CurrentGrid setting. - if (mGrid.empty()) + // override the helper uri if it was passed in + std::string cmd_line_helper_uri = gSavedSettings.getString("CmdLineHelperURI"); + if(!cmd_line_helper_uri.empty()) { - - mGrid = gSavedSettings.getString("CurrentGrid"); + grid[GRID_HELPER_URI_VALUE] = cmd_line_helper_uri; + grid_dirty = true; } - - if (mGrid.empty() || !mGridList.has(mGrid)) + + // override the login page if it was passed in + std::string cmd_line_login_page = gSavedSettings.getString("LoginPage"); + if(!cmd_line_login_page.empty()) { - // the grid name was empty, or the grid isn't actually in the list, then set it to the - // appropriate default. - LL_INFOS("GridManager") << "Resetting grid as grid name " << mGrid << " is not in the list" << LL_ENDL; - mGrid = MAINGRID; + grid[GRID_LOGIN_PAGE_VALUE] = cmd_line_login_page; + grid_dirty = true; } - LL_INFOS("GridManager") << "Selected grid is " << mGrid << LL_ENDL; - gSavedSettings.setString("CurrentGrid", mGrid); + + if(grid_dirty) + { + // add the grid with the additional values, or update the + // existing grid if it exists with the given values + addGrid(grid); + } + LL_DEBUGS("GridManager") << "Selected grid is " << mGrid << LL_ENDL; + setGridChoice(mGrid); + if(mGridList[mGrid][GRID_LOGIN_URI_VALUE].isArray()) + { + llinfos << "is array" << llendl; + } } LLGridManager::~LLGridManager() @@ -401,7 +407,7 @@ void LLGridManager::addGrid(LLSD& grid_data) grid_data[GRID_LOGIN_IDENTIFIER_TYPES].append(CRED_IDENTIFIER_TYPE_ACCOUNT); } - LL_INFOS("GridManager") << "ADDING: " << grid << LL_ENDL; + LL_DEBUGS("GridManager") << "ADDING: " << grid << LL_ENDL; mGridList[grid] = grid_data; } } @@ -467,6 +473,7 @@ std::map LLGridManager::getKnownGrids(bool favorite_on return result; } + void LLGridManager::setGridChoice(const std::string& grid) { // Set the grid choice based on a string. @@ -477,35 +484,37 @@ void LLGridManager::setGridChoice(const std::string& grid) // loop through. We could do just a hash lookup but we also want to match // on label - for(LLSD::map_iterator grid_iter = mGridList.beginMap(); - grid_iter != mGridList.endMap(); - grid_iter++) + std::string grid_name = grid; + if(!mGridList.has(grid_name)) { - if((grid == grid_iter->first) || - (grid == grid_iter->second[GRID_LABEL_VALUE].asString())) - { - mGrid = grid_iter->second[GRID_VALUE].asString(); - gSavedSettings.setString("CurrentGrid", grid_iter->second[GRID_VALUE]); - return; - - } + // case insensitive + grid_name = getGridByLabel(grid); + } + + if(grid_name.empty()) + { + // the grid was not in the list of grids. + LLSD grid_data = LLSD::emptyMap(); + grid_data[GRID_VALUE] = grid; + addGrid(grid_data); } - LLSD grid_data = LLSD::emptyMap(); - grid_data[GRID_VALUE] = grid; - addGrid(grid_data); mGrid = grid; gSavedSettings.setString("CurrentGrid", grid); } -std::string LLGridManager::getGridByLabel( const std::string &grid_label) +std::string LLGridManager::getGridByLabel( const std::string &grid_label, bool case_sensitive) { for(LLSD::map_iterator grid_iter = mGridList.beginMap(); grid_iter != mGridList.endMap(); grid_iter++) { - if (grid_iter->second.has(GRID_LABEL_VALUE) && (grid_iter->second[GRID_LABEL_VALUE].asString() == grid_label)) + if (grid_iter->second.has(GRID_LABEL_VALUE)) { - return grid_iter->first; + if (0 == (case_sensitive?LLStringUtil::compareStrings(grid_label, grid_iter->second[GRID_LABEL_VALUE].asString()): + LLStringUtil::compareInsensitive(grid_label, grid_iter->second[GRID_LABEL_VALUE].asString()))) + { + return grid_iter->first; + } } } return std::string(); -- cgit v1.3 From cf05f59dd923d623bc50135214a488a29664ab95 Mon Sep 17 00:00:00 2001 From: Roxie Linden Date: Thu, 27 May 2010 17:20:29 -0700 Subject: EXT-7388 - --grid command-line argument does nothing Fix up overriding of --loginuri --loginpage --helperuri --- indra/newview/llpanellogin.cpp | 3 +- indra/newview/llurldispatcher.cpp | 3 +- indra/newview/llviewernetwork.cpp | 88 ++++++++++++++++++---------- indra/newview/llviewernetwork.h | 18 ++---- indra/newview/tests/llviewernetwork_test.cpp | 26 ++++---- 5 files changed, 80 insertions(+), 58 deletions(-) (limited to 'indra/newview/llviewernetwork.cpp') diff --git a/indra/newview/llpanellogin.cpp b/indra/newview/llpanellogin.cpp index 0009f7203a..c8dae024cf 100644 --- a/indra/newview/llpanellogin.cpp +++ b/indra/newview/llpanellogin.cpp @@ -1164,7 +1164,8 @@ void LLPanelLogin::onServerComboLostFocus(LLFocusableElement* fe) void LLPanelLogin::updateLoginPanelLinks() { - LLSD grid_data = LLGridManager::getInstance()->getGridInfo(); + LLSD grid_data; + LLGridManager::getInstance()->getGridInfo(grid_data); bool system_grid = grid_data.has(GRID_IS_SYSTEM_GRID_VALUE); // need to call through sInstance, as it's called from onSelectServer, which diff --git a/indra/newview/llurldispatcher.cpp b/indra/newview/llurldispatcher.cpp index 9efa6c4108..cbaa7248a2 100644 --- a/indra/newview/llurldispatcher.cpp +++ b/indra/newview/llurldispatcher.cpp @@ -215,7 +215,8 @@ void LLURLDispatcherImpl::regionHandleCallback(U64 region_handle, const LLSLURL& LLSD args; args["SLURL"] = slurl.getLocationString(); args["CURRENT_GRID"] = LLGridManager::getInstance()->getGridLabel(); - LLSD grid_info = LLGridManager::getInstance()->getGridInfo(slurl.getGrid()); + LLSD grid_info; + LLGridManager::getInstance()->getGridInfo(slurl.getGrid(), grid_info); if(grid_info.has(GRID_LABEL_VALUE)) { diff --git a/indra/newview/llviewernetwork.cpp b/indra/newview/llviewernetwork.cpp index 619deaf50b..a81bb2e6f2 100644 --- a/indra/newview/llviewernetwork.cpp +++ b/indra/newview/llviewernetwork.cpp @@ -296,7 +296,6 @@ void LLGridManager::initialize(const std::string& grid_file) // any grid list entries with. LLSD grid = LLSD::emptyMap(); - bool grid_dirty = false; if(mGridList.has(mGrid)) { grid = mGridList[mGrid]; @@ -304,52 +303,53 @@ void LLGridManager::initialize(const std::string& grid_file) else { grid[GRID_VALUE] = mGrid; - grid_dirty = true; + // add the grid with the additional values, or update the + // existing grid if it exists with the given values + addGrid(grid); + } + + LL_DEBUGS("GridManager") << "Selected grid is " << mGrid << LL_ENDL; + setGridChoice(mGrid); + if(mGridList[mGrid][GRID_LOGIN_URI_VALUE].isArray()) + { + llinfos << "is array" << llendl; } +} + +LLGridManager::~LLGridManager() +{ + saveFavorites(); +} + +void LLGridManager::getGridInfo(const std::string &grid, LLSD& grid_info) +{ + + grid_info = mGridList[grid]; + + // override any grid data with the command line info. LLSD cmd_line_login_uri = gSavedSettings.getLLSD("CmdLineLoginURI"); if (cmd_line_login_uri.isString()) - { - grid_dirty = true; - grid[GRID_LOGIN_URI_VALUE] = LLSD::emptyArray(); - grid[GRID_LOGIN_URI_VALUE].append(cmd_line_login_uri); + { + grid_info[GRID_LOGIN_URI_VALUE] = LLSD::emptyArray(); + grid_info[GRID_LOGIN_URI_VALUE].append(cmd_line_login_uri); } // override the helper uri if it was passed in std::string cmd_line_helper_uri = gSavedSettings.getString("CmdLineHelperURI"); if(!cmd_line_helper_uri.empty()) { - grid[GRID_HELPER_URI_VALUE] = cmd_line_helper_uri; - grid_dirty = true; + grid_info[GRID_HELPER_URI_VALUE] = cmd_line_helper_uri; } // override the login page if it was passed in std::string cmd_line_login_page = gSavedSettings.getString("LoginPage"); if(!cmd_line_login_page.empty()) { - grid[GRID_LOGIN_PAGE_VALUE] = cmd_line_login_page; - grid_dirty = true; - } - - - if(grid_dirty) - { - // add the grid with the additional values, or update the - // existing grid if it exists with the given values - addGrid(grid); - } - LL_DEBUGS("GridManager") << "Selected grid is " << mGrid << LL_ENDL; - setGridChoice(mGrid); - if(mGridList[mGrid][GRID_LOGIN_URI_VALUE].isArray()) - { - llinfos << "is array" << llendl; - } + grid_info[GRID_LOGIN_PAGE_VALUE] = cmd_line_login_page; + } } -LLGridManager::~LLGridManager() -{ - saveFavorites(); -} // // LLGridManager::addGrid - add a grid to the grid list, populating the needed values @@ -523,6 +523,12 @@ std::string LLGridManager::getGridByLabel( const std::string &grid_label, bool c void LLGridManager::getLoginURIs(std::vector& uris) { uris.clear(); + LLSD cmd_line_login_uri = gSavedSettings.getLLSD("CmdLineLoginURI"); + if (cmd_line_login_uri.isString()) + { + uris.push_back(cmd_line_login_uri); + return; + } for (LLSD::array_iterator llsd_uri = mGridList[mGrid][GRID_LOGIN_URI_VALUE].beginArray(); llsd_uri != mGridList[mGrid][GRID_LOGIN_URI_VALUE].endArray(); llsd_uri++) @@ -531,7 +537,29 @@ void LLGridManager::getLoginURIs(std::vector& uris) } } -bool LLGridManager::isInProductionGrid() +std::string LLGridManager::getHelperURI() +{ + std::string cmd_line_helper_uri = gSavedSettings.getString("CmdLineHelperURI"); + if(!cmd_line_helper_uri.empty()) + { + return cmd_line_helper_uri; + } + return mGridList[mGrid][GRID_HELPER_URI_VALUE]; +} + +std::string LLGridManager::getLoginPage() +{ + // override the login page if it was passed in + std::string cmd_line_login_page = gSavedSettings.getString("LoginPage"); + if(!cmd_line_login_page.empty()) + { + return cmd_line_login_page; + } + + return mGridList[mGrid][GRID_LOGIN_PAGE_VALUE]; +} + +bool LLGridManager::LLGridManager::isInProductionGrid() { // *NOTE:Mani This used to compare GRID_INFO_AGNI to gGridChoice, // but it seems that loginURI trumps that. diff --git a/indra/newview/llviewernetwork.h b/indra/newview/llviewernetwork.h index a99e32f701..8c3a15b7cf 100644 --- a/indra/newview/llviewernetwork.h +++ b/indra/newview/llviewernetwork.h @@ -89,17 +89,7 @@ public: // by default only return the user visible grids std::map getKnownGrids(bool favorites_only=FALSE); - LLSD getGridInfo(const std::string& grid) - { - if(mGridList.has(grid)) - { - return mGridList[grid]; - } - else - { - return LLSD(); - } - } + void getGridInfo(const std::string& grid, LLSD &grid_info); // current grid management @@ -112,8 +102,8 @@ public: std::string getGridLabel() { return mGridList[mGrid][GRID_LABEL_VALUE]; } std::string getGrid() const { return mGrid; } void getLoginURIs(std::vector& uris); - std::string getHelperURI() {return mGridList[mGrid][GRID_HELPER_URI_VALUE];} - std::string getLoginPage() {return mGridList[mGrid][GRID_LOGIN_PAGE_VALUE];} + std::string getHelperURI(); + std::string getLoginPage(); std::string getGridLoginID() { return mGridList[mGrid][GRID_ID_VALUE]; } std::string getLoginPage(const std::string& grid) { return mGridList[grid][GRID_LOGIN_PAGE_VALUE]; } void getLoginIdentifierTypes(LLSD& idTypes) { idTypes = mGridList[mGrid][GRID_LOGIN_IDENTIFIER_TYPES]; } @@ -125,7 +115,7 @@ public: std::string getAppSLURLBase(const std::string& grid); std::string getAppSLURLBase() { return getAppSLURLBase(mGrid); } - LLSD getGridInfo() { return mGridList[mGrid]; } + void getGridInfo(LLSD &grid_info) { getGridInfo(mGrid, grid_info); } std::string getGridByLabel( const std::string &grid_label, bool case_sensitive = false); diff --git a/indra/newview/tests/llviewernetwork_test.cpp b/indra/newview/tests/llviewernetwork_test.cpp index a3b11e706a..5fba5eb69c 100644 --- a/indra/newview/tests/llviewernetwork_test.cpp +++ b/indra/newview/tests/llviewernetwork_test.cpp @@ -148,7 +148,8 @@ namespace tut known_grids[std::string("util.agni.lindenlab.com")], std::string("Agni")); ensure_equals("None exists", known_grids[""], "None"); - LLSD grid = LLGridManager::getInstance()->getGridInfo("util.agni.lindenlab.com"); + LLSD grid; + LLGridManager::getInstance()->getGridInfo("util.agni.lindenlab.com", grid); ensure("Grid info for agni is a map", grid.isMap()); ensure_equals("name is correct for agni", grid[GRID_VALUE].asString(), std::string("util.agni.lindenlab.com")); @@ -190,7 +191,8 @@ namespace tut // assure Agni doesn't get overwritten - LLSD grid = LLGridManager::getInstance()->getGridInfo("util.agni.lindenlab.com"); + LLSD grid; + LLGridManager::getInstance()->getGridInfo("util.agni.lindenlab.com", grid); ensure_equals("Agni grid label was not modified by grid file", grid[GRID_LABEL_VALUE].asString(), std::string("Agni")); @@ -215,7 +217,7 @@ namespace tut ensure_equals("Grid file adds to name<->label map", known_grids["grid1"], std::string("mylabel")); - grid = LLGridManager::getInstance()->getGridInfo("grid1"); + LLGridManager::getInstance()->getGridInfo("grid1", grid); ensure_equals("grid file grid name is set", grid[GRID_VALUE].asString(), std::string("grid1")); ensure_equals("grid file label is set", @@ -267,7 +269,7 @@ namespace tut known_grids.size(), 24); ensure_equals("Custom Command line grid is added to the list of grids", known_grids["mycustomgridchoice"], std::string("mycustomgridchoice")); - grid = LLGridManager::getInstance()->getGridInfo("mycustomgridchoice"); + LLGridManager::getInstance()->getGridInfo("mycustomgridchoice", grid); ensure_equals("Custom Command line grid name is set", grid[GRID_VALUE].asString(), std::string("mycustomgridchoice")); ensure_equals("Custom Command line grid label is set", @@ -298,7 +300,7 @@ namespace tut std::map known_grids = LLGridManager::getInstance()->getKnownGrids(); ensure_equals("Override known grid login uri: No grids are added", known_grids.size(), 23); - grid = LLGridManager::getInstance()->getGridInfo(); + LLGridManager::getInstance()->getGridInfo(grid); ensure("Override known grid login uri: login uri is an array", grid[GRID_LOGIN_URI_VALUE].isArray()); ensure_equals("Override known grid login uri: Command line grid login uri is set", @@ -317,7 +319,7 @@ namespace tut gCmdLineLoginURI = "https://my.login.uri/cgi-bin/login.cgi"; LLGridManager::getInstance()->initialize("grid_test.xml"); known_grids = LLGridManager::getInstance()->getKnownGrids(); - grid = LLGridManager::getInstance()->getGridInfo(); + LLGridManager::getInstance()->getGridInfo(grid); ensure_equals("Override custom grid login uri: Grid is added", known_grids.size(), 24); ensure("Override custom grid login uri: login uri is an array", @@ -347,7 +349,7 @@ namespace tut std::map known_grids = LLGridManager::getInstance()->getKnownGrids(); ensure_equals("Override known grid helper uri: No grids are added", known_grids.size(), 23); - grid = LLGridManager::getInstance()->getGridInfo(); + LLGridManager::getInstance()->getGridInfo(grid); ensure("Override known known helper uri: login uri is an array", grid[GRID_LOGIN_URI_VALUE].isArray()); ensure_equals("Override known grid helper uri: login uri is not changed", @@ -368,7 +370,7 @@ namespace tut known_grids = LLGridManager::getInstance()->getKnownGrids(); ensure_equals("Override custom grid helper uri: grids is added", known_grids.size(), 24); - grid = LLGridManager::getInstance()->getGridInfo(); + LLGridManager::getInstance()->getGridInfo(grid); ensure("Override custom helper uri: login uri is an array", grid[GRID_LOGIN_URI_VALUE].isArray()); ensure_equals("Override custom grid helper uri: login uri is not changed", @@ -396,7 +398,7 @@ namespace tut std::map known_grids = LLGridManager::getInstance()->getKnownGrids(); ensure_equals("Override known grid login page: No grids are added", known_grids.size(), 23); - grid = LLGridManager::getInstance()->getGridInfo(); + LLGridManager::getInstance()->getGridInfo(grid); ensure("Override known grid login page: Command line grid login uri is an array", grid[GRID_LOGIN_URI_VALUE].isArray()); ensure_equals("Override known grid login page: login uri is not changed", @@ -417,7 +419,7 @@ namespace tut known_grids = LLGridManager::getInstance()->getKnownGrids(); ensure_equals("Override custom grid login page: grids are added", known_grids.size(), 24); - grid = LLGridManager::getInstance()->getGridInfo(); + LLGridManager::getInstance()->getGridInfo(grid); ensure("Override custom grid login page: Command line grid login uri is an array", grid[GRID_LOGIN_URI_VALUE].isArray()); ensure_equals("Override custom grid login page: login uri is not changed", @@ -464,7 +466,7 @@ namespace tut ensure("Is myaddedgrid a production grid", !LLGridManager::getInstance()->isInProductionGrid()); LLGridManager::getInstance()->setFavorite(); - grid = LLGridManager::getInstance()->getGridInfo("myaddedgrid"); + LLGridManager::getInstance()->getGridInfo("myaddedgrid", grid); ensure("setting favorite", grid.has(GRID_IS_FAVORITE_VALUE)); } @@ -477,7 +479,7 @@ namespace tut // adding a grid with simply a name will populate the values. grid[GRID_VALUE] = "myaddedgrid"; LLGridManager::getInstance()->addGrid(grid); - grid = LLGridManager::getInstance()->getGridInfo("myaddedgrid"); + LLGridManager::getInstance()->getGridInfo("myaddedgrid", grid); ensure_equals("name based grid has name value", grid[GRID_VALUE].asString(), -- cgit v1.3 From 6b8fec008bbf5da5687a7438ad56559237b5a850 Mon Sep 17 00:00:00 2001 From: Roxie Linden Date: Fri, 28 May 2010 01:03:17 -0700 Subject: Fix build break --- indra/newview/llviewernetwork.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llviewernetwork.cpp') diff --git a/indra/newview/llviewernetwork.cpp b/indra/newview/llviewernetwork.cpp index a81bb2e6f2..fec112b9e7 100644 --- a/indra/newview/llviewernetwork.cpp +++ b/indra/newview/llviewernetwork.cpp @@ -559,7 +559,7 @@ std::string LLGridManager::getLoginPage() return mGridList[mGrid][GRID_LOGIN_PAGE_VALUE]; } -bool LLGridManager::LLGridManager::isInProductionGrid() +bool LLGridManager::isInProductionGrid() { // *NOTE:Mani This used to compare GRID_INFO_AGNI to gGridChoice, // but it seems that loginURI trumps that. -- cgit v1.3