jni: is loggable speedup, not within signal
Speedup by telling __android_is_loggable interface it will not be called within a signal handler. This saves two system calls. Bug: 25563384 Change-Id: Ib8188641c8c76e5aa848476da98596be6b8e5040
This commit is contained in:
@@ -42,7 +42,9 @@ struct levels_t {
|
||||
static levels_t levels;
|
||||
|
||||
static jboolean isLoggable(const char* tag, jint level) {
|
||||
return __android_log_is_loggable(level, tag, ANDROID_LOG_INFO);
|
||||
return __android_log_is_loggable(level, tag,
|
||||
ANDROID_LOG_INFO |
|
||||
ANDROID_LOGGABLE_FLAG_NOT_WITHIN_SIGNAL);
|
||||
}
|
||||
|
||||
static jboolean android_util_Log_isLoggable(JNIEnv* env, jobject clazz, jstring tag, jint level)
|
||||
|
||||
Reference in New Issue
Block a user