Skip to content

Commit 5190063

Browse files
MonkopediaAndroid (Google) Code Review
authored andcommitted
Merge "Synchronize on all sendProxyBroadcast calls" into lmp-dev
2 parents ae30948 + cf0f97a commit 5190063

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

services/core/java/com/android/server/ConnectivityService.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ public class ConnectivityService extends IConnectivityManager.Stub {
403403
private ArrayList mInetLog;
404404

405405
// track the current default http proxy - tell the world if we get a new one (real change)
406-
private ProxyInfo mDefaultProxy = null;
406+
private volatile ProxyInfo mDefaultProxy = null;
407407
private Object mProxyLock = new Object();
408408
private boolean mDefaultProxyDisabled = false;
409409

@@ -2537,12 +2537,12 @@ public void setGlobalProxy(ProxyInfo proxyProperties) {
25372537
} finally {
25382538
Binder.restoreCallingIdentity(token);
25392539
}
2540-
}
25412540

2542-
if (mGlobalProxy == null) {
2543-
proxyProperties = mDefaultProxy;
2541+
if (mGlobalProxy == null) {
2542+
proxyProperties = mDefaultProxy;
2543+
}
2544+
sendProxyBroadcast(proxyProperties);
25442545
}
2545-
sendProxyBroadcast(proxyProperties);
25462546
}
25472547

25482548
private void loadGlobalProxy() {

0 commit comments

Comments
 (0)