Skip to content

Commit 939caef

Browse files
committed
Fix NPE
Bug: 7357742 Change-Id: I4d12d137b9d5ebf5c6739cbd4405de3f90a3d846
1 parent a30d969 commit 939caef

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

wifi/java/android/net/wifi/WifiManager.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1983,7 +1983,9 @@ public void captivePortalCheckComplete() {
19831983

19841984
protected void finalize() throws Throwable {
19851985
try {
1986-
mHandler.getLooper().quit();
1986+
if (mHandler != null && mHandler.getLooper() != null) {
1987+
mHandler.getLooper().quit();
1988+
}
19871989
} finally {
19881990
super.finalize();
19891991
}

0 commit comments

Comments
 (0)