diff options
author | aunsane <aunsane@gmail.com> | 2018-04-15 14:26:08 +0300 |
---|---|---|
committer | aunsane <aunsane@gmail.com> | 2018-04-15 14:26:08 +0300 |
commit | f469f317d78360f0c316152ad862628b35efc7fc (patch) | |
tree | f10e7a6d1f3c12a4b8d3f15954818ef40fd5be48 /protocols/Tox | |
parent | b55b81d78a7db972287d635e712311ffcacfd931 (diff) |
Tox: remove unneeded log level in release build
Diffstat (limited to 'protocols/Tox')
-rw-r--r-- | protocols/Tox/src/tox_core.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/protocols/Tox/src/tox_core.cpp b/protocols/Tox/src/tox_core.cpp index 1132486213..f3fa95b84d 100644 --- a/protocols/Tox/src/tox_core.cpp +++ b/protocols/Tox/src/tox_core.cpp @@ -101,6 +101,12 @@ void CToxProto::OnToxLog(Tox*, TOX_LOG_LEVEL level, const char *file, uint32_t l {
CToxProto *proto = (CToxProto*)user_data;
- if (level > TOX_LOG_LEVEL_INFO)
- proto->debugLogA("TOXCORE: %s at %s(...) in %s:%u", message, func, file, line);
+#ifdef _DEBUG
+ if (level < TOX_LOG_LEVEL_INFO)
+#else
+ if (level < TOX_LOG_LEVEL_ERROR)
+#endif
+ return;
+
+ proto->debugLogA("TOXCORE: %s at %s(...) in %s:%u", message, func, file, line);
}
\ No newline at end of file |