summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelmaininventory.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llpanelmaininventory.cpp')
-rwxr-xr-xindra/newview/llpanelmaininventory.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/indra/newview/llpanelmaininventory.cpp b/indra/newview/llpanelmaininventory.cpp
index 37273a7793..17c0b226d0 100755
--- a/indra/newview/llpanelmaininventory.cpp
+++ b/indra/newview/llpanelmaininventory.cpp
@@ -160,10 +160,9 @@ BOOL LLPanelMainInventory::postBuild()
}
// Now load the stored settings from disk, if available.
- std::ostringstream filterSaveName;
- filterSaveName << gDirUtilp->getExpandedFilename(LL_PATH_PER_SL_ACCOUNT, FILTERS_FILENAME);
- LL_INFOS() << "LLPanelMainInventory::init: reading from " << filterSaveName.str() << LL_ENDL;
- llifstream file(filterSaveName.str());
+ std::string filterSaveName(gDirUtilp->getExpandedFilename(LL_PATH_PER_SL_ACCOUNT, FILTERS_FILENAME));
+ LL_INFOS() << "LLPanelMainInventory::init: reading from " << filterSaveName << LL_ENDL;
+ llifstream file(filterSaveName.c_str());
LLSD savedFilterState;
if (file.is_open())
{
@@ -243,16 +242,17 @@ LLPanelMainInventory::~LLPanelMainInventory( void )
}
}
- std::ostringstream filterSaveName;
- filterSaveName << gDirUtilp->getExpandedFilename(LL_PATH_PER_SL_ACCOUNT, FILTERS_FILENAME);
- llofstream filtersFile(filterSaveName.str());
+ std::string filterSaveName(gDirUtilp->getExpandedFilename(LL_PATH_PER_SL_ACCOUNT, FILTERS_FILENAME));
+ llofstream filtersFile(filterSaveName.c_str());
if(!LLSDSerialize::toPrettyXML(filterRoot, filtersFile))
{
- LL_WARNS() << "Could not write to filters save file " << filterSaveName.str() << LL_ENDL;
+ LL_WARNS() << "Could not write to filters save file " << filterSaveName << LL_ENDL;
}
else
+ {
filtersFile.close();
-
+ }
+
gInventory.removeObserver(this);
delete mSavedFolderState;
}