summaryrefslogtreecommitdiff
path: root/qadevOOo
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2015-12-30 14:43:15 +0000
committerCaolán McNamara <caolanm@redhat.com>2015-12-30 14:43:15 +0000
commit20cb57cde026c8cc6cf9470eb3100b6a884d864e (patch)
treefb666cf37c7a4520dad1fe21966edbbc6502b211 /qadevOOo
parentcd6b730536e7f9ae1b70a00a15ed83e853dfa357 (diff)
coverity#1326979 SBSC: String concatenation in loop using + operator
Change-Id: Iddf881369ff8a177fba9ebe9a673291a9b8ed431
Diffstat (limited to 'qadevOOo')
-rw-r--r--qadevOOo/runner/util/XMLTools.java12
1 files changed, 6 insertions, 6 deletions
diff --git a/qadevOOo/runner/util/XMLTools.java b/qadevOOo/runner/util/XMLTools.java
index 5feda4867ccc..6930a96bfa6a 100644
--- a/qadevOOo/runner/util/XMLTools.java
+++ b/qadevOOo/runner/util/XMLTools.java
@@ -461,18 +461,18 @@ public class XMLTools {
*/
@Override
public String toString() {
- String ret = "<" + name ;
+ StringBuffer ret = new StringBuffer("<" + name);
for (int i = 0; i < attrList.length; i++) {
- ret += " " + attrList[i][0] + "=";
+ ret.append(" ").append(attrList[i][0]).append("=");
if (attrList[i][2] == null) {
- ret += "(not specified)";
+ ret.append("(not specified)");
} else {
- ret += "\"" + attrList[i][2] + "\"";
+ ret.append("\"").append(attrList[i][2]).append("\"");
}
}
- ret += ">";
+ ret.append(">");
- return ret ;
+ return ret.toString();
}
private boolean checkAttr(int attrListIdx, XAttributeList list) {