Allow blocking calls to InstrumentationWatcher

InstrumentationWatchers are used in tests, therefore
we are not concerned about them misbehaving on
production devices.

Fixes: 147705910
Test: run an instrumentation test and
  there are no ONEWAY_FLAG warnings from BinderProxy

Change-Id: I323d4598a4d8e5e754251d8d4f27c5c6a2faea2f
This commit is contained in:
Dmitri Plotnikov
2020-02-14 10:29:03 -08:00
parent 5b55f124d8
commit 92e9d96e37

View File

@@ -18,6 +18,7 @@ package com.android.server.am;
import android.app.IInstrumentationWatcher;
import android.content.ComponentName;
import android.os.Binder;
import android.os.Bundle;
import android.os.Process;
import android.os.RemoteException;
@@ -109,6 +110,8 @@ public class InstrumentationReporter {
mName = name;
mResultCode = resultCode;
mResults = results;
Binder.allowBlocking(mWatcher.asBinder());
}
}