Loading api/current.xml +112 −2 Original line number Diff line number Diff line Loading @@ -77980,7 +77980,7 @@ type="float" transient="false" volatile="false" value="0.0010f" value="0.001f" static="true" final="true" deprecated="not deprecated" Loading Loading @@ -124950,6 +124950,116 @@ </parameter> </method> </class> <class name="StrictMode" extends="java.lang.Object" abstract="false" static="false" final="true" deprecated="not deprecated" visibility="public" > <method name="getThreadBlockingPolicy" return="int" abstract="false" native="false" synchronized="false" static="true" final="false" deprecated="not deprecated" visibility="public" > </method> <method name="setThreadBlockingPolicy" return="void" abstract="false" native="false" synchronized="false" static="true" final="false" deprecated="not deprecated" visibility="public" > <parameter name="policyMask" type="int"> </parameter> </method> <field name="DISALLOW_DISK_READ" type="int" transient="false" volatile="false" value="2" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="DISALLOW_DISK_WRITE" type="int" transient="false" volatile="false" value="1" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="DISALLOW_NETWORK" type="int" transient="false" volatile="false" value="4" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="PENALTY_DEATH" type="int" transient="false" volatile="false" value="64" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="PENALTY_DIALOG" type="int" transient="false" volatile="false" value="32" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="PENALTY_DROPBOX" type="int" transient="false" volatile="false" value="128" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="PENALTY_LOG" type="int" transient="false" volatile="false" value="16" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> </class> <class name="SystemClock" extends="java.lang.Object" abstract="false" Loading Loading @@ -218779,7 +218889,7 @@ deprecated="not deprecated" visibility="public" > <parameter name="arg0" type="T"> <parameter name="t" type="T"> </parameter> </method> </interface> core/java/android/app/ActivityManagerNative.java +24 −0 Original line number Diff line number Diff line Loading @@ -1062,6 +1062,15 @@ public abstract class ActivityManagerNative extends Binder implements IActivityM return true; } case HANDLE_APPLICATION_STRICT_MODE_VIOLATION_TRANSACTION: { data.enforceInterface(IActivityManager.descriptor); IBinder app = data.readStrongBinder(); ApplicationErrorReport.CrashInfo ci = new ApplicationErrorReport.CrashInfo(data); handleApplicationStrictModeViolation(app, ci); reply.writeNoException(); return true; } case SIGNAL_PERSISTENT_PROCESSES_TRANSACTION: { data.enforceInterface(IActivityManager.descriptor); int sig = data.readInt(); Loading Loading @@ -2523,6 +2532,7 @@ class ActivityManagerProxy implements IActivityManager reply.recycle(); data.recycle(); } public boolean handleApplicationWtf(IBinder app, String tag, ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException { Loading @@ -2540,6 +2550,20 @@ class ActivityManagerProxy implements IActivityManager return res; } public void handleApplicationStrictModeViolation(IBinder app, ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException { Parcel data = Parcel.obtain(); Parcel reply = Parcel.obtain(); data.writeInterfaceToken(IActivityManager.descriptor); data.writeStrongBinder(app); crashInfo.writeToParcel(data, 0); mRemote.transact(HANDLE_APPLICATION_STRICT_MODE_VIOLATION_TRANSACTION, data, reply, 0); reply.readException(); reply.recycle(); data.recycle(); } public void signalPersistentProcesses(int sig) throws RemoteException { Parcel data = Parcel.obtain(); Parcel reply = Parcel.obtain(); Loading core/java/android/app/ActivityThread.java +16 −0 Original line number Diff line number Diff line Loading @@ -42,6 +42,7 @@ import android.database.sqlite.SQLiteDebug; import android.database.sqlite.SQLiteDebug.DbStats; import android.graphics.Bitmap; import android.graphics.Canvas; import android.os.Build; import android.os.Bundle; import android.os.Debug; import android.os.Handler; Loading @@ -53,6 +54,7 @@ import android.os.ParcelFileDescriptor; import android.os.Process; import android.os.RemoteException; import android.os.ServiceManager; import android.os.StrictMode; import android.os.SystemClock; import android.util.AndroidRuntimeException; import android.util.Config; Loading Loading @@ -4131,6 +4133,20 @@ public final class ActivityThread { data.info = getPackageInfoNoCheck(data.appInfo); /** * For system applications on userdebug/eng builds, log stack * traces of disk and network access to dropbox for analysis. */ if ((data.appInfo.flags&ApplicationInfo.FLAG_SYSTEM) != 0 && !"user".equals(Build.TYPE)) { StrictMode.setDropBoxManager(ContextImpl.createDropBoxManager()); StrictMode.setThreadBlockingPolicy( StrictMode.DISALLOW_DISK_WRITE | StrictMode.DISALLOW_DISK_READ | StrictMode.DISALLOW_NETWORK | StrictMode.PENALTY_DROPBOX); } /** * Switch this process to density compatibility mode if needed. */ Loading core/java/android/app/ContextImpl.java +7 −3 Original line number Diff line number Diff line Loading @@ -1157,12 +1157,16 @@ class ContextImpl extends Context { return mAudioManager; } /* package */ static DropBoxManager createDropBoxManager() { IBinder b = ServiceManager.getService(DROPBOX_SERVICE); IDropBoxManagerService service = IDropBoxManagerService.Stub.asInterface(b); return new DropBoxManager(service); } private DropBoxManager getDropBoxManager() { synchronized (mSync) { if (mDropBoxManager == null) { IBinder b = ServiceManager.getService(DROPBOX_SERVICE); IDropBoxManagerService service = IDropBoxManagerService.Stub.asInterface(b); mDropBoxManager = new DropBoxManager(service); mDropBoxManager = createDropBoxManager(); } } return mDropBoxManager; Loading core/java/android/app/IActivityManager.java +4 −1 Original line number Diff line number Diff line Loading @@ -256,6 +256,8 @@ public interface IActivityManager extends IInterface { ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException; public boolean handleApplicationWtf(IBinder app, String tag, ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException; public void handleApplicationStrictModeViolation(IBinder app, ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException; /* * This will deliver the specified signal to all the persistent processes. Currently only Loading Loading @@ -516,4 +518,5 @@ public interface IActivityManager extends IInterface { int START_ACTIVITY_WITH_CONFIG_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+106; int GET_RUNNING_EXTERNAL_APPLICATIONS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+107; int FINISH_HEAVY_WEIGHT_APP_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+108; int HANDLE_APPLICATION_STRICT_MODE_VIOLATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+109; } Loading
api/current.xml +112 −2 Original line number Diff line number Diff line Loading @@ -77980,7 +77980,7 @@ type="float" transient="false" volatile="false" value="0.0010f" value="0.001f" static="true" final="true" deprecated="not deprecated" Loading Loading @@ -124950,6 +124950,116 @@ </parameter> </method> </class> <class name="StrictMode" extends="java.lang.Object" abstract="false" static="false" final="true" deprecated="not deprecated" visibility="public" > <method name="getThreadBlockingPolicy" return="int" abstract="false" native="false" synchronized="false" static="true" final="false" deprecated="not deprecated" visibility="public" > </method> <method name="setThreadBlockingPolicy" return="void" abstract="false" native="false" synchronized="false" static="true" final="false" deprecated="not deprecated" visibility="public" > <parameter name="policyMask" type="int"> </parameter> </method> <field name="DISALLOW_DISK_READ" type="int" transient="false" volatile="false" value="2" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="DISALLOW_DISK_WRITE" type="int" transient="false" volatile="false" value="1" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="DISALLOW_NETWORK" type="int" transient="false" volatile="false" value="4" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="PENALTY_DEATH" type="int" transient="false" volatile="false" value="64" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="PENALTY_DIALOG" type="int" transient="false" volatile="false" value="32" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="PENALTY_DROPBOX" type="int" transient="false" volatile="false" value="128" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> <field name="PENALTY_LOG" type="int" transient="false" volatile="false" value="16" static="true" final="true" deprecated="not deprecated" visibility="public" > </field> </class> <class name="SystemClock" extends="java.lang.Object" abstract="false" Loading Loading @@ -218779,7 +218889,7 @@ deprecated="not deprecated" visibility="public" > <parameter name="arg0" type="T"> <parameter name="t" type="T"> </parameter> </method> </interface>
core/java/android/app/ActivityManagerNative.java +24 −0 Original line number Diff line number Diff line Loading @@ -1062,6 +1062,15 @@ public abstract class ActivityManagerNative extends Binder implements IActivityM return true; } case HANDLE_APPLICATION_STRICT_MODE_VIOLATION_TRANSACTION: { data.enforceInterface(IActivityManager.descriptor); IBinder app = data.readStrongBinder(); ApplicationErrorReport.CrashInfo ci = new ApplicationErrorReport.CrashInfo(data); handleApplicationStrictModeViolation(app, ci); reply.writeNoException(); return true; } case SIGNAL_PERSISTENT_PROCESSES_TRANSACTION: { data.enforceInterface(IActivityManager.descriptor); int sig = data.readInt(); Loading Loading @@ -2523,6 +2532,7 @@ class ActivityManagerProxy implements IActivityManager reply.recycle(); data.recycle(); } public boolean handleApplicationWtf(IBinder app, String tag, ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException { Loading @@ -2540,6 +2550,20 @@ class ActivityManagerProxy implements IActivityManager return res; } public void handleApplicationStrictModeViolation(IBinder app, ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException { Parcel data = Parcel.obtain(); Parcel reply = Parcel.obtain(); data.writeInterfaceToken(IActivityManager.descriptor); data.writeStrongBinder(app); crashInfo.writeToParcel(data, 0); mRemote.transact(HANDLE_APPLICATION_STRICT_MODE_VIOLATION_TRANSACTION, data, reply, 0); reply.readException(); reply.recycle(); data.recycle(); } public void signalPersistentProcesses(int sig) throws RemoteException { Parcel data = Parcel.obtain(); Parcel reply = Parcel.obtain(); Loading
core/java/android/app/ActivityThread.java +16 −0 Original line number Diff line number Diff line Loading @@ -42,6 +42,7 @@ import android.database.sqlite.SQLiteDebug; import android.database.sqlite.SQLiteDebug.DbStats; import android.graphics.Bitmap; import android.graphics.Canvas; import android.os.Build; import android.os.Bundle; import android.os.Debug; import android.os.Handler; Loading @@ -53,6 +54,7 @@ import android.os.ParcelFileDescriptor; import android.os.Process; import android.os.RemoteException; import android.os.ServiceManager; import android.os.StrictMode; import android.os.SystemClock; import android.util.AndroidRuntimeException; import android.util.Config; Loading Loading @@ -4131,6 +4133,20 @@ public final class ActivityThread { data.info = getPackageInfoNoCheck(data.appInfo); /** * For system applications on userdebug/eng builds, log stack * traces of disk and network access to dropbox for analysis. */ if ((data.appInfo.flags&ApplicationInfo.FLAG_SYSTEM) != 0 && !"user".equals(Build.TYPE)) { StrictMode.setDropBoxManager(ContextImpl.createDropBoxManager()); StrictMode.setThreadBlockingPolicy( StrictMode.DISALLOW_DISK_WRITE | StrictMode.DISALLOW_DISK_READ | StrictMode.DISALLOW_NETWORK | StrictMode.PENALTY_DROPBOX); } /** * Switch this process to density compatibility mode if needed. */ Loading
core/java/android/app/ContextImpl.java +7 −3 Original line number Diff line number Diff line Loading @@ -1157,12 +1157,16 @@ class ContextImpl extends Context { return mAudioManager; } /* package */ static DropBoxManager createDropBoxManager() { IBinder b = ServiceManager.getService(DROPBOX_SERVICE); IDropBoxManagerService service = IDropBoxManagerService.Stub.asInterface(b); return new DropBoxManager(service); } private DropBoxManager getDropBoxManager() { synchronized (mSync) { if (mDropBoxManager == null) { IBinder b = ServiceManager.getService(DROPBOX_SERVICE); IDropBoxManagerService service = IDropBoxManagerService.Stub.asInterface(b); mDropBoxManager = new DropBoxManager(service); mDropBoxManager = createDropBoxManager(); } } return mDropBoxManager; Loading
core/java/android/app/IActivityManager.java +4 −1 Original line number Diff line number Diff line Loading @@ -256,6 +256,8 @@ public interface IActivityManager extends IInterface { ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException; public boolean handleApplicationWtf(IBinder app, String tag, ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException; public void handleApplicationStrictModeViolation(IBinder app, ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException; /* * This will deliver the specified signal to all the persistent processes. Currently only Loading Loading @@ -516,4 +518,5 @@ public interface IActivityManager extends IInterface { int START_ACTIVITY_WITH_CONFIG_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+106; int GET_RUNNING_EXTERNAL_APPLICATIONS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+107; int FINISH_HEAVY_WEIGHT_APP_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+108; int HANDLE_APPLICATION_STRICT_MODE_VIOLATION_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+109; }