am 37fc8cc7: am b724d251: Merge "Enable strictmode logging in system_server & add a lock." into gingerbread
Merge commit '37fc8cc7b87133eddacaeab60cabefaf4a7b9bdd' * commit '37fc8cc7b87133eddacaeab60cabefaf4a7b9bdd': Enable strictmode logging in system_server & add a lock.
This commit is contained in:
@@ -532,6 +532,17 @@ class ServerThread extends Thread {
|
||||
}
|
||||
});
|
||||
|
||||
// For debug builds, log event loop stalls to dropbox for analysis.
|
||||
// Similar logic also appears in ActivityThread.java for system apps.
|
||||
if (!"user".equals(Build.TYPE)) {
|
||||
Slog.i(TAG, "Enabling StrictMode for system server.");
|
||||
StrictMode.setThreadPolicy(
|
||||
StrictMode.DISALLOW_DISK_WRITE |
|
||||
StrictMode.DISALLOW_DISK_READ |
|
||||
StrictMode.DISALLOW_NETWORK |
|
||||
StrictMode.PENALTY_DROPBOX);
|
||||
}
|
||||
|
||||
Looper.loop();
|
||||
Slog.d(TAG, "System ServerThread is exiting!");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user