summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2025-03-03 22:14:47 +0200
committerAndrey Kleshchev <117672381+akleshchev@users.noreply.github.com>2025-03-04 17:23:05 +0200
commitc98002daa68163563b6c946a6d26c4c8b74176ae (patch)
tree91e67ae8b86d10585b43fb1a103a571ac8e75534
parented394cd5a07d69e9007ad50819a01911645cadcd (diff)
#3643 Use bugsplat attributes on MacOS
-rw-r--r--indra/llinventory/llsettingsbase.cpp11
-rw-r--r--indra/llinventory/llsettingsbase.h5
-rw-r--r--indra/llxml/llxmlnode.cpp1
-rw-r--r--indra/newview/llappdelegate-objc.mm3
-rw-r--r--indra/newview/llappviewer.h3
-rw-r--r--indra/newview/llappviewermacosx-for-objc.h1
-rw-r--r--indra/newview/llappviewermacosx.cpp27
-rw-r--r--indra/newview/llpanelprofilepicks.cpp4
8 files changed, 33 insertions, 22 deletions
diff --git a/indra/llinventory/llsettingsbase.cpp b/indra/llinventory/llsettingsbase.cpp
index 0ee71de3a1..d483b33288 100644
--- a/indra/llinventory/llsettingsbase.cpp
+++ b/indra/llinventory/llsettingsbase.cpp
@@ -130,17 +130,6 @@ void LLSettingsBase::saveValuesIfNeeded()
}
//=========================================================================
-void LLSettingsBase::lerpSettings(LLSettingsBase &other, F64 mix)
-{
- LL_PROFILE_ZONE_SCOPED_CATEGORY_ENVIRONMENT;
- saveValuesIfNeeded();
- stringset_t skip = getSkipInterpolateKeys();
- stringset_t slerps = getSlerpKeys();
- mSettings = interpolateSDMap(mSettings, other.getSettings(), other.getParameterMap(), mix, skip, slerps);
- setDirtyFlag(true);
- loadValuesFromLLSD();
-}
-
void LLSettingsBase::lerpVector2(LLVector2& a, const LLVector2& b, F32 mix)
{
a.mV[0] = lerp(a.mV[0], b.mV[0], mix);
diff --git a/indra/llinventory/llsettingsbase.h b/indra/llinventory/llsettingsbase.h
index 816ff3e111..7de71588ef 100644
--- a/indra/llinventory/llsettingsbase.h
+++ b/indra/llinventory/llsettingsbase.h
@@ -348,13 +348,8 @@ protected:
LLSettingsBase();
LLSettingsBase(const LLSD setting);
- static LLSD settingValidation(LLSD settings);
-
typedef std::set<std::string> stringset_t;
- // combining settings objects. Customize for specific setting types
- virtual void lerpSettings(LLSettingsBase &other, BlendFactor mix);
-
// combining settings maps where it can based on mix rate
// @settings initial value (mix==0)
// @other target value (mix==1)
diff --git a/indra/llxml/llxmlnode.cpp b/indra/llxml/llxmlnode.cpp
index 92bcb1a2ae..ec616cefbc 100644
--- a/indra/llxml/llxmlnode.cpp
+++ b/indra/llxml/llxmlnode.cpp
@@ -306,6 +306,7 @@ void LLXMLNode::addChild(LLXMLNodePtr& new_child)
// virtual
LLXMLNodePtr LLXMLNode::createChild(const char* name, bool is_attribute)
{
+ // Todo: validate to make sure node name is valid? (no spaces, etc)
return createChild(gStringTable.addStringEntry(name), is_attribute);
}
diff --git a/indra/newview/llappdelegate-objc.mm b/indra/newview/llappdelegate-objc.mm
index 1090888c1c..d4b05dde72 100644
--- a/indra/newview/llappdelegate-objc.mm
+++ b/indra/newview/llappdelegate-objc.mm
@@ -301,7 +301,8 @@ struct AttachmentInfo
AttachmentInfo(metadata.logFilePathname, "text/plain"),
AttachmentInfo(metadata.userSettingsPathname, "text/xml"),
AttachmentInfo(metadata.accountSettingsPathname, "text/xml"),
- AttachmentInfo(metadata.staticDebugPathname, "text/xml")
+ AttachmentInfo(metadata.staticDebugPathname, "text/xml"),
+ AttachmentInfo(metadata.attributesPathname, "text/xml")
};
secondLogPath = metadata.secondLogFilePathname;
diff --git a/indra/newview/llappviewer.h b/indra/newview/llappviewer.h
index 10d71c9d42..3da0246ccf 100644
--- a/indra/newview/llappviewer.h
+++ b/indra/newview/llappviewer.h
@@ -157,9 +157,6 @@ public:
void loadNameCache();
void saveNameCache();
- void loadExperienceCache();
- void saveExperienceCache();
-
void removeMarkerFiles();
void recordSessionToMarker();
diff --git a/indra/newview/llappviewermacosx-for-objc.h b/indra/newview/llappviewermacosx-for-objc.h
index 5a69cd93fc..c3f1e35872 100644
--- a/indra/newview/llappviewermacosx-for-objc.h
+++ b/indra/newview/llappviewermacosx-for-objc.h
@@ -41,6 +41,7 @@ void clearDumpLogsDir();
struct CrashMetadata
{
std::string logFilePathname;
+ std::string attributesPathname;
std::string userSettingsPathname;
std::string accountSettingsPathname;
std::string staticDebugPathname;
diff --git a/indra/newview/llappviewermacosx.cpp b/indra/newview/llappviewermacosx.cpp
index 4162c0479a..aab6d00573 100644
--- a/indra/newview/llappviewermacosx.cpp
+++ b/indra/newview/llappviewermacosx.cpp
@@ -172,6 +172,8 @@ CrashMetadataSingleton::CrashMetadataSingleton()
// Note: we depend on being able to read the static_debug_info.log file
// from the *previous* run before we overwrite it with the new one for
// *this* run. LLAppViewer initialization must happen in the Right Order.
+
+ // Todo: consider converting static file into bugspalt attributes file
staticDebugPathname = *gViewerAppPtr->getStaticDebugFile();
std::ifstream static_file(staticDebugPathname);
LLSD info;
@@ -215,7 +217,32 @@ CrashMetadataSingleton::CrashMetadataSingleton()
}
}
}
+
+ // Populate bugsplat attributes
+ LLXMLNodePtr out_node = new LLXMLNode("XmlCrashContext", false);
+
+ out_node->createChild("OS", false)->setValue(OSInfo);
+ out_node->createChild("AppState", false)->setValue(info["StartupState"].asString());
+ out_node->createChild("GraphicsCard", false)->setValue(info["GraphicsCard"].asString());
+ out_node->createChild("GLVersion", false)->setValue(info["GLInfo"]["GLVersion"].asString());
+ out_node->createChild("GLRenderer", false)->setValue(info["GLInfo"]["GLRenderer"].asString());
+ out_node->createChild("RAM", false)->setValue(info["RAMInfo"]["Physical"].asString());
+
+ if (!out_node->isNull())
+ {
+ attributesPathname = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, "CrashContext.xml");
+ LLFILE* fp = LLFile::fopen(attributesPathname, "w");
+
+ if (fp != NULL)
+ {
+ LLXMLNode::writeHeaderToFile(fp);
+ out_node->writeToFile(fp);
+
+ fclose(fp);
+ }
+ }
}
+ // else Todo: consider fillig at least some values, like OS
}
// Avoid having to compile all of our LLSingleton machinery in Objective-C++.
diff --git a/indra/newview/llpanelprofilepicks.cpp b/indra/newview/llpanelprofilepicks.cpp
index c2edc58687..09b8011ce4 100644
--- a/indra/newview/llpanelprofilepicks.cpp
+++ b/indra/newview/llpanelprofilepicks.cpp
@@ -55,8 +55,8 @@
static LLPanelInjector<LLPanelProfilePicks> t_panel_profile_picks("panel_profile_picks");
static LLPanelInjector<LLPanelProfilePick> t_panel_profile_pick("panel_profile_pick");
-static const F32 REQUEST_TIMOUT = 60;
-static const F32 LOCATION_CACHE_TIMOUT = 900;
+constexpr F32 REQUEST_TIMOUT = 60;
+constexpr F32 LOCATION_CACHE_TIMOUT = 900;
class LLPickHandler : public LLCommandHandler
{