0391a879f7
See the previous commit moving SetLogger and SetAborter to liblog for motivation. This creates more harmony between the two mechanisms in libbase and liblog for checking loggability. Currently: 1) libbase filters all messages based on its minimum log priority. For example, if minimum log priority in libbase remained at its default, but a tag was specifically opted into DEBUG logs via log.tag.<tag>, libbase would not print this log. 2) liblog ignores libbase's minimum log priority. For example if a process called SetMinimumLogPriority(WARNING) but used a library that logged via liblog's ALOGI macro, that log would still be printed even though the process intends on filtering out those INFO messages. With this change: 1) If both a minimum log priority and a priority through log.tag.<tag> are set, then the lower of the two values is used. 2) If only one or the other is set, then that value is used. This fixes the two issues described above. 3) If neither of these values are set, then the default of using INFO is unchanged. Bug: 116329414 Bug: 119867234 Test: libbase and liblog minimum log priority tests Change-Id: Icb49b30b9d93bf797470e23730ae9e537931bb6c |
||
---|---|---|
.. | ||
Android.bp | ||
AndroidTest.xml | ||
libc_test.cpp | ||
liblog_benchmark.cpp | ||
liblog_global_state.cpp | ||
liblog_host_test.cpp | ||
liblog_test.cpp | ||
log_id_test.cpp | ||
log_radio_test.cpp | ||
log_read_test.cpp | ||
log_system_test.cpp | ||
log_time_test.cpp | ||
log_wrap_test.cpp | ||
logprint_test.cpp | ||
rwlock_test.cpp |