Use config resource for tcp buffer size
bug:16549611 Change-Id: I48426f6b746e4bd9729bdd529d81b163ff5112a9
This commit is contained in:
@@ -250,9 +250,6 @@ class EthernetNetworkFactory {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private static final String TCP_BUFFER_SIZES_ETHERNET =
|
|
||||||
"524288,1048576,3145728,524288,1048576,2097152";
|
|
||||||
|
|
||||||
/* Called by the NetworkFactory on the handler thread. */
|
/* Called by the NetworkFactory on the handler thread. */
|
||||||
public void onRequestNetwork() {
|
public void onRequestNetwork() {
|
||||||
// TODO: Handle DHCP renew.
|
// TODO: Handle DHCP renew.
|
||||||
@@ -290,7 +287,11 @@ class EthernetNetworkFactory {
|
|||||||
linkProperties.setHttpProxy(config.getHttpProxy());
|
linkProperties.setHttpProxy(config.getHttpProxy());
|
||||||
}
|
}
|
||||||
|
|
||||||
linkProperties.setTcpBufferSizes(TCP_BUFFER_SIZES_ETHERNET);
|
String tcpBufferSizes = mContext.getResources().getString(
|
||||||
|
com.android.internal.R.string.config_ethernet_tcp_buffers);
|
||||||
|
if (TextUtils.isEmpty(tcpBufferSizes) == false) {
|
||||||
|
linkProperties.setTcpBufferSizes(tcpBufferSizes);
|
||||||
|
}
|
||||||
|
|
||||||
synchronized(EthernetNetworkFactory.this) {
|
synchronized(EthernetNetworkFactory.this) {
|
||||||
if (mNetworkAgent != null) {
|
if (mNetworkAgent != null) {
|
||||||
|
|||||||
Reference in New Issue
Block a user