summaryrefslogtreecommitdiff
path: root/indra/llcommon/llerror.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llcommon/llerror.cpp')
-rw-r--r--indra/llcommon/llerror.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/indra/llcommon/llerror.cpp b/indra/llcommon/llerror.cpp
index 6a62860c3f..7887a942e9 100644
--- a/indra/llcommon/llerror.cpp
+++ b/indra/llcommon/llerror.cpp
@@ -1488,3 +1488,20 @@ namespace LLError
}
}
+bool debugLoggingEnabled(const std::string& tag)
+{
+ const char* tags[] = {tag.c_str()};
+ ::size_t tag_count = 1;
+ LLError::CallSite _site(LLError::LEVEL_DEBUG, __FILE__, __LINE__,
+ typeid(_LL_CLASS_TO_LOG), __FUNCTION__, false, tags, tag_count);
+ if (LL_UNLIKELY(_site.shouldLog()))
+ {
+ return true;
+ }
+ else
+ {
+ return false;
+ }
+}
+
+