diff options
author | George Kadianakis <desnacked@riseup.net> | 2019-09-30 13:47:06 +0300 |
---|---|---|
committer | George Kadianakis <desnacked@riseup.net> | 2019-09-30 13:47:06 +0300 |
commit | fc760c5088394741ac8c83706be6b737aef79beb (patch) | |
tree | faaf0a7faf92b83c30de6e83ac5d8cb36a0ffb4b /src/lib/log | |
parent | 4673cb8168cbacd817c38c3f1ca5c9e88d10b053 (diff) | |
parent | d30a042fa8348028e0bea6f3e46cba1ffbe5adcc (diff) | |
download | tor-fc760c5088394741ac8c83706be6b737aef79beb.tar.gz tor-fc760c5088394741ac8c83706be6b737aef79beb.zip |
Merge branch 'tor-github/pr/1356'
Diffstat (limited to 'src/lib/log')
-rw-r--r-- | src/lib/log/log.c | 4 | ||||
-rw-r--r-- | src/lib/log/log.h | 6 |
2 files changed, 6 insertions, 4 deletions
diff --git a/src/lib/log/log.c b/src/lib/log/log.c index a5db085c30..4463bff618 100644 --- a/src/lib/log/log.c +++ b/src/lib/log/log.c @@ -55,10 +55,6 @@ #include <android/log.h> #endif // HAVE_ANDROID_LOG_H. -/** Given a severity, yields an index into log_severity_list_t.masks to use - * for that severity. */ -#define SEVERITY_MASK_IDX(sev) ((sev) - LOG_ERR) - /** @{ */ /** The string we stick at the end of a log message when it is too long, * and its length. */ diff --git a/src/lib/log/log.h b/src/lib/log/log.h index 4291418eb6..da4bcbe608 100644 --- a/src/lib/log/log.h +++ b/src/lib/log/log.h @@ -297,4 +297,10 @@ MOCK_DECL(STATIC void, logv, (int severity, log_domain_mask_t domain, va_list ap) CHECK_PRINTF(5,0)); #endif +#if defined(LOG_PRIVATE) || defined(TOR_UNIT_TESTS) +/** Given a severity, yields an index into log_severity_list_t.masks to use + * for that severity. */ +#define SEVERITY_MASK_IDX(sev) ((sev) - LOG_ERR) +#endif + #endif /* !defined(TOR_TORLOG_H) */ |