summaryrefslogtreecommitdiff
path: root/indra/llcommon
diff options
context:
space:
mode:
authorAndrew A. de Laix <alain@lindenlab.com>2010-06-09 15:47:37 -0700
committerAndrew A. de Laix <alain@lindenlab.com>2010-06-09 15:47:37 -0700
commitf2f7f7b3bb2c8466e2a07f8f586a1a63fdae8a66 (patch)
tree9c74f8e5ca2601bbdf87a4b5e034b76784bdacea /indra/llcommon
parent163b767944caa4b2a474abf93e64eaeac1f02587 (diff)
parent4bbca7c086724da1af4f8cb6b22e6de8320a0b1b (diff)
merge
Diffstat (limited to 'indra/llcommon')
-rw-r--r--indra/llcommon/llerror.cpp10
-rw-r--r--indra/llcommon/llerror.h2
-rw-r--r--indra/llcommon/llstring.h4
-rw-r--r--indra/llcommon/tests/llerror_test.cpp9
4 files changed, 13 insertions, 12 deletions
diff --git a/indra/llcommon/llerror.cpp b/indra/llcommon/llerror.cpp
index 41ff5849f4..d06d6baf85 100644
--- a/indra/llcommon/llerror.cpp
+++ b/indra/llcommon/llerror.cpp
@@ -954,7 +954,12 @@ namespace LLError
std::string class_name = className(site.mClassInfo);
std::string function_name = functionName(site.mFunction);
+#if LL_LINUX
+ // gross, but typeid comparison seems to always fail here with gcc4.1
+ if (0 != strcmp(site.mClassInfo.name(), typeid(NoClassInfo).name()))
+#else
if (site.mClassInfo != typeid(NoClassInfo))
+#endif // LL_LINUX
{
function_name = class_name + "::" + function_name;
}
@@ -1079,7 +1084,12 @@ namespace LLError
#if LL_WINDOWS
// DevStudio: __FUNCTION__ already includes the full class name
#else
+ #if LL_LINUX
+ // gross, but typeid comparison seems to always fail here with gcc4.1
+ if (0 != strcmp(site.mClassInfo.name(), typeid(NoClassInfo).name()))
+ #else
if (site.mClassInfo != typeid(NoClassInfo))
+ #endif // LL_LINUX
{
prefix << className(site.mClassInfo) << "::";
}
diff --git a/indra/llcommon/llerror.h b/indra/llcommon/llerror.h
index 09812de2b8..e64ee5e081 100644
--- a/indra/llcommon/llerror.h
+++ b/indra/llcommon/llerror.h
@@ -179,7 +179,7 @@ namespace LLError
{ return s; }
// used to indicate the end of a message
- class NoClassInfo { };
+ class LL_COMMON_API NoClassInfo { };
// used to indicate no class info known for logging
//LLCallStacks keeps track of call stacks and output the call stacks to log file
diff --git a/indra/llcommon/llstring.h b/indra/llcommon/llstring.h
index ad8f8632a2..8071c8aa2d 100644
--- a/indra/llcommon/llstring.h
+++ b/indra/llcommon/llstring.h
@@ -249,7 +249,7 @@ public:
/////////////////////////////////////////////////////////////////////////////////////////
// Static Utility functions that operate on std::strings
- static std::basic_string<T> null;
+ static const std::basic_string<T> null;
typedef std::map<LLFormatMapString, LLFormatMapString> format_map_t;
LL_COMMON_API static void getTokens(const std::basic_string<T>& instr, std::vector<std::basic_string<T> >& tokens, const std::basic_string<T>& delims);
@@ -371,7 +371,7 @@ private:
LL_COMMON_API static size_type getSubstitution(const std::basic_string<T>& instr, size_type& start, std::vector<std::basic_string<T> >& tokens);
};
-template<class T> std::basic_string<T> LLStringUtilBase<T>::null;
+template<class T> const std::basic_string<T> LLStringUtilBase<T>::null;
template<class T> std::string LLStringUtilBase<T>::sLocale;
typedef LLStringUtilBase<char> LLStringUtil;
diff --git a/indra/llcommon/tests/llerror_test.cpp b/indra/llcommon/tests/llerror_test.cpp
index 6785d0cf17..1558df231a 100644
--- a/indra/llcommon/tests/llerror_test.cpp
+++ b/indra/llcommon/tests/llerror_test.cpp
@@ -545,15 +545,6 @@ namespace tut
// output order
void ErrorTestObject::test<10>()
{
-#if LL_LINUX
- skip("Fails on Linux, see comments");
-// on Linux:
-// [error, 10] fail: 'order is time type location function message: expected
-// '1947-07-08T03:04:05Z INFO: llcommon/tests/llerror_test.cpp(268) :
-// writeReturningLocationAndFunction: apple' actual
-// '1947-07-08T03:04:05Z INFO: llcommon/tests/llerror_test.cpp(268) :
-// LLError::NoClassInfo::writeReturningLocationAndFunction: apple''
-#endif
LLError::setPrintLocation(true);
LLError::setTimeFunction(roswell);
mRecorder.setWantsTime(true);