Merge "liblog: return -EPERM if a log_is_loggable() returns false" into rvc-dev

This commit is contained in:
Tom Cherry 2020-04-20 15:05:26 +00:00 committed by Android (Google) Code Review
commit 2dd0ddff06
1 changed files with 4 additions and 4 deletions

View File

@ -330,7 +330,7 @@ int __android_log_buf_write(int bufID, int prio, const char* tag, const char* ms
ErrnoRestorer errno_restorer;
if (!__android_log_is_loggable(prio, tag, ANDROID_LOG_VERBOSE)) {
return 0;
return -EPERM;
}
__android_log_message log_message = {
@ -343,7 +343,7 @@ int __android_log_vprint(int prio, const char* tag, const char* fmt, va_list ap)
ErrnoRestorer errno_restorer;
if (!__android_log_is_loggable(prio, tag, ANDROID_LOG_VERBOSE)) {
return 0;
return -EPERM;
}
char buf[LOG_BUF_SIZE];
@ -360,7 +360,7 @@ int __android_log_print(int prio, const char* tag, const char* fmt, ...) {
ErrnoRestorer errno_restorer;
if (!__android_log_is_loggable(prio, tag, ANDROID_LOG_VERBOSE)) {
return 0;
return -EPERM;
}
va_list ap;
@ -380,7 +380,7 @@ int __android_log_buf_print(int bufID, int prio, const char* tag, const char* fm
ErrnoRestorer errno_restorer;
if (!__android_log_is_loggable(prio, tag, ANDROID_LOG_VERBOSE)) {
return 0;
return -EPERM;
}
va_list ap;