coverity#1326973 SBSC: String concatenation in loop using + operator

Change-Id: I8fb8afa2951201106443f76fde3f55ead24d43c2
This commit is contained in:
Caolán McNamara
2015-12-30 14:56:20 +00:00
parent f852edc6db
commit 5ff0c0c283

View File

@@ -250,19 +250,21 @@ public class UnoUrl {
while (true) {
char c = ',';
String aKey = "";
String aValue = "";
StringBuffer sb = new StringBuffer();
while ((pos < paramString.length())
&& ((c = paramString.charAt(pos++)) != '=')) {
aKey += c;
sb.append(c);
}
String aKey = sb.toString();
sb = new StringBuffer();
while ((pos < paramString.length())
&& ((c = paramString.charAt(pos++)) != ',')
&& c != ';') {
aValue += c;
sb.append(c);
}
String aValue = sb.toString();
if ((aKey.length() > 0) && (aValue.length() > 0)) {