Skip to content

Commit

Permalink
[JENKINS-32428] Escape xml and json outputs in REST API - fix 2 (#123)
Browse files Browse the repository at this point in the history
[JENKINS-32428] Escape xml and json outputs in REST API - fix 2 (#120)
  • Loading branch information
Rechi authored and oleg-nenashev committed Jun 29, 2017
1 parent 1b9811e commit df82446
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -140,7 +140,7 @@ private String escapeXml(String xml) {
}

private String escapeJson(String json) {
return json.replace("\"", "\\\"").replace("\\", "\\\\");
return json.replace("\\", "\\\\").replace("\"", "\\\"");
}

//TODO: Throw errors in responses?
Expand Down

0 comments on commit df82446

Please sign in to comment.