Merge "Enable fdtrack in system_server." am: 62d4abfd06

Change-Id: I7792d474064696ce24dfca47823c73aab79c59f3
This commit is contained in:
Automerger Merge Worker
2020-01-31 16:42:57 +00:00
2 changed files with 69 additions and 1 deletions

View File

@@ -353,6 +353,12 @@ public final class SystemServer {
*/
private static native void initZygoteChildHeapProfiling();
/**
* Spawn a thread that monitors for fd leaks.
*/
private static native void spawnFdLeakCheckThread();
/**
* The main entry point from zygote.
*/
@@ -484,6 +490,11 @@ public final class SystemServer {
initZygoteChildHeapProfiling();
}
// Debug builds - spawn a thread to monitor for fd leaks.
if (Build.IS_DEBUGGABLE) {
spawnFdLeakCheckThread();
}
// Check whether we failed to shut down last time we tried.
// This call may not return.
performPendingShutdown();