Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0e090825 authored by Robert Greenwalt's avatar Robert Greenwalt
Browse files

Notify people of empty proxies too.

We were telling people when the proxy changed, except if it was changed to null.
bug:5263946

Change-Id: I83416dac8fe992168a8aafd5676f9faee4e484d0
parent 22aa7805
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -2618,7 +2618,8 @@ public class ConnectivityService extends IConnectivityManager.Stub {
            }
        }
        if (VDBG) log("changing default proxy to " + proxy);
        if ((proxy == null && mGlobalProxy == null) || proxy.equals(mGlobalProxy)) return;

        // global trumps default, if set, ignore this.
        if (mGlobalProxy != null) return;
        sendProxyBroadcast(proxy);
    }
+3 −1
Original line number Diff line number Diff line
@@ -1768,8 +1768,10 @@ public final class GsmDataConnectionTracker extends DataConnectionTracker {
            ApnSetting apn = apnContext.getApnSetting();
            if (apn.proxy != null && apn.proxy.length() != 0) {
                try {
                    String port = apn.port;
                    if (TextUtils.isEmpty(port)) port = "8080";
                    ProxyProperties proxy = new ProxyProperties(apn.proxy,
                            Integer.parseInt(apn.port), null);
                            Integer.parseInt(port), null);
                    dcac.setLinkPropertiesHttpProxySync(proxy);
                } catch (NumberFormatException e) {
                    loge("onDataSetupComplete: NumberFormatException making ProxyProperties (" +