Tweak user agent building to avoid multiple spaces

Bug: 3211038
 The building of the user agent could previously have multiple sequential
 spaces. This was causing the CTS test to fail.

Change-Id: I13fc76ba6b97ee84dd44461b4d03b6ca70b48cdf
This commit is contained in:
John Reck
2011-01-07 18:45:33 -08:00
parent 5e63e2515f
commit 36fd7a39ca

View File

@@ -485,11 +485,12 @@ public class WebSettings {
// default to "en"
buffer.append("en");
}
buffer.append("; ");
buffer.append(";");
// add the model for the release build
if ("REL".equals(Build.VERSION.CODENAME)) {
final String model = Build.MODEL;
if (model.length() > 0) {
buffer.append(" ");
buffer.append(model);
}
}