Merge "fdtrack: emit the most common stack in the abort message."
This commit is contained in:
@@ -100,16 +100,9 @@ static void android_server_SystemServer_initZygoteChildHeapProfiling(JNIEnv* /*
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void android_server_SystemServer_fdtrackAbort(JNIEnv*, jobject) {
|
static void android_server_SystemServer_fdtrackAbort(JNIEnv*, jobject) {
|
||||||
raise(BIONIC_SIGNAL_FDTRACK);
|
sigval val;
|
||||||
|
val.sival_int = 1;
|
||||||
// Wait for a bit to allow fdtrack to dump backtraces to logcat.
|
sigqueue(getpid(), BIONIC_SIGNAL_FDTRACK, val);
|
||||||
std::this_thread::sleep_for(5s);
|
|
||||||
|
|
||||||
// Abort on a different thread to avoid ART dumping runtime stacks.
|
|
||||||
std::thread([]() {
|
|
||||||
LOG_ALWAYS_FATAL("b/140703823: aborting due to fd leak: check logs for fd "
|
|
||||||
"backtraces");
|
|
||||||
}).join();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static jlong android_server_SystemServer_startIncrementalService(JNIEnv* env, jclass klass,
|
static jlong android_server_SystemServer_startIncrementalService(JNIEnv* env, jclass klass,
|
||||||
|
|||||||
Reference in New Issue
Block a user