summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorCallum Prentice <callum@lindenlab.com>2010-03-04 14:31:10 -0800
committerCallum Prentice <callum@lindenlab.com>2010-03-04 14:31:10 -0800
commit2ce7807c9e15f3941d9aa2db57cbb26cda42ba09 (patch)
treecf41de0c1931ee93755968d2e15ba8a42b529c82 /indra
parent458895a75d61d2c7321e2074c11efc350263987b (diff)
Fix for EXT-5960 (Store media cookies per user rather than per viewer)
Reviewed by RN and MW
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llviewermedia.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/indra/newview/llviewermedia.cpp b/indra/newview/llviewermedia.cpp
index 344c4c469b..4c09b7cf3e 100644
--- a/indra/newview/llviewermedia.cpp
+++ b/indra/newview/llviewermedia.cpp
@@ -1229,6 +1229,19 @@ LLPluginClassMedia* LLViewerMediaImpl::newSourceFromMediaType(std::string media_
std::string user_data_path = gDirUtilp->getOSUserAppDir();
user_data_path += gDirUtilp->getDirDelimiter();
+ // Fix for EXT-5960 - make browser profile specific to user (cache, cookies etc.)
+ // If the linden username returned is blank, that can only mean we are
+ // at the login page displaying login Web page or Web browser test via Develop menu.
+ // In this case we just use whatever gDirUtilp->getOSUserAppDir() gives us (this
+ // is what we always used before this change)
+ std::string linden_user_dir = gDirUtilp->getLindenUserDir();
+ if ( ! linden_user_dir.empty() )
+ {
+ // gDirUtilp->getLindenUserDir() is whole path, not just Linden name
+ user_data_path = linden_user_dir;
+ user_data_path += gDirUtilp->getDirDelimiter();
+ };
+
// See if the plugin executable exists
llstat s;
if(LLFile::stat(launcher_name, &s))