From adb8bf98d93ce390004fd3da53d815c142679e20 Mon Sep 17 00:00:00 2001 From: Robert Greenwalt Date: Mon, 20 Aug 2012 11:15:39 -0700 Subject: [PATCH] Update TCP buffer size when switching network type Import of non-merging change 41612 from AOSP When PDP connects in GSM network, the TCP buffer window size is set to max 8760. If the phone swicthes to UMTS, the TCP buffer size is not updated to UMTS, i.e. GPRS buffer size is still used with limited data transfer spead as a result. This fix makes sure the TCP buffer size is updated when switching network type. Change-Id: Ic44a557677ffe629e83ce1f522a9f058bee6e7b2 --- services/java/com/android/server/ConnectivityService.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/services/java/com/android/server/ConnectivityService.java b/services/java/com/android/server/ConnectivityService.java index 375ba68d42..cb6ce4b3b2 100644 --- a/services/java/com/android/server/ConnectivityService.java +++ b/services/java/com/android/server/ConnectivityService.java @@ -2592,6 +2592,11 @@ public class ConnectivityService extends IConnectivityManager.Stub { // @see bug/4455071 handleConnectivityChange(info.getType(), false); break; + case NetworkStateTracker.EVENT_NETWORK_SUBTYPE_CHANGED: + info = (NetworkInfo) msg.obj; + type = info.getType(); + updateNetworkSettings(mNetTrackers[type]); + break; } } }