voidsignalExceptionForError(JNIEnv*env,jobjectobj,status_terr,boolcanThrowRemoteException){switch(err){...caseFAILED_TRANSACTION:ALOGE("!!! FAILED BINDER TRANSACTION !!!");// TransactionTooLargeException is a checked exception, only throw from certain methods.// FIXME: Transaction too large is the most common reason for FAILED_TRANSACTION// but it is not the only one. The Binder driver can return BR_FAILED_REPLY// for other reasons also, such as if the transaction is malformed or// refers to an FD that has been closed. We should change the driver// to enable us to distinguish these cases in the future.jniThrowException(env,canThrowRemoteException?"android/os/TransactionTooLargeException":"java/lang/RuntimeException",NULL);break;...}}
privatestaticDrawablesBackground;@OverrideprotectedvoidonCreate(Bundlestate){super.onCreate(state);TextViewlabel=newTextView(this);label.setText("Leaks are bad");if(sBackground==null){sBackground=getDrawable(R.drawable.large_bitmap);}label.setBackgroundDrawable(sBackground);setContentView(label);}