Merge "Remove an NPE in tearDown" into main
This commit is contained in:
@@ -198,7 +198,8 @@ public abstract class AbstractRestrictBackgroundNetworkTestCase {
|
|||||||
protected void tearDown() throws Exception {
|
protected void tearDown() throws Exception {
|
||||||
executeShellCommand("cmd netpolicy stop-watching");
|
executeShellCommand("cmd netpolicy stop-watching");
|
||||||
mServiceClient.unbind();
|
mServiceClient.unbind();
|
||||||
if (mLock.isHeld()) mLock.release();
|
final PowerManager.WakeLock lock = mLock;
|
||||||
|
if (null != lock && lock.isHeld()) lock.release();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected int getUid(String packageName) throws Exception {
|
protected int getUid(String packageName) throws Exception {
|
||||||
|
|||||||
Reference in New Issue
Block a user