Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Escape control characters in XML. #6672

Merged
merged 1 commit into from
Jul 16, 2016
Merged

Fix: Escape control characters in XML. #6672

merged 1 commit into from
Jul 16, 2016

Conversation

Gerhut
Copy link
Contributor

@Gerhut Gerhut commented Jul 14, 2016

What issue does this pull request address?
#6673

What changes did you make? (Give an overview)

Fix XML escape with ASCII control characters

Is there anything you'd like reviewers to focus on?

When generating XML report with control characters (like "\b" or "\n", they
are sometimes used in JavaScript object keys and will cause messages.),
some XML parser like SAX will crash.

Escape these characters will avoid crashing.

@mention-bot
Copy link

@Gerhut, thanks for your PR! By analyzing the annotation information on this pull request, we identified @gajus, @michaelficarra and @xjamundx to be potential reviewers

@eslintbot
Copy link

Thanks for the pull request, @Gerhut! I took a look to make sure it's ready for merging and found some changes are needed:

  • Pull requests with code require an issue to be mentioned at the end of the commit summary, such as (fixes #1234). Please update the commit summary with an issue (file a new issue if one doesn't already exist).

Can you please update the pull request to address these?

(More information can be found in our pull request guide.)

@jquerybot
Copy link

Thank you for your pull request. It looks like this may be your first contribution to a jQuery Foundation project, if so we need you to sign our Contributor License Agreement (CLA).

📝 Please visit http://contribute.jquery.org/CLA/ to sign.

After you signed, the PR is checked again automatically after a minute. If there's still an issue, please reply here to let us know.


If you've already signed our CLA, it's possible your git author information doesn't match your CLA signature (both your name and email have to match), for more information, check the status of your CLA check.

@eslintbot
Copy link

Thanks for the pull request, @Gerhut! I took a look to make sure it's ready for merging and found some changes are needed:

  • Pull requests with code require an issue to be mentioned at the end of the commit summary, such as (fixes #1234). Please update the commit summary with an issue (file a new issue if one doesn't already exist).

Can you please update the pull request to address these?

(More information can be found in our pull request guide.)

@eslintbot
Copy link

Thanks for the pull request, @Gerhut! I took a look to make sure it's ready for merging and found some changes are needed:

  • Pull requests with code require an issue to be mentioned at the end of the commit summary, such as (fixes #1234). Please update the commit summary with an issue (file a new issue if one doesn't already exist).

Can you please update the pull request to address these?

(More information can be found in our pull request guide.)

@eslintbot
Copy link

LGTM

@eslintbot
Copy link

LGTM

@vitorbal vitorbal added the do not merge This pull request should not be merged yet label Jul 14, 2016
@vitorbal
Copy link
Member

Thanks @Gerhut! Adding 'do not merge' until the issue gets accepted.

@@ -42,7 +42,7 @@ function xmlEscape(s) {
case "'":
return "'";
default:
throw new Error("unreachable");
return "&#" + c.charCodeAt() + ";";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pass 0 explicitly.

@eslintbot
Copy link

LGTM

When generating XML report with control characters (like "\b" or "\n", they
are sometimes used in JavaScript object keys and will cause messages.),
some XML parser like SAX will crash.

Escape these characters will avoid crashing.
@eslintbot
Copy link

LGTM

@nzakas nzakas removed the do not merge This pull request should not be merged yet label Jul 15, 2016
@nzakas
Copy link
Member

nzakas commented Jul 15, 2016

LGTM, just waiting for others to take a look.

@ilyavolodin
Copy link
Member

LGTM

@nzakas nzakas merged commit 9f96086 into eslint:master Jul 16, 2016
@eslint-deprecated eslint-deprecated bot locked and limited conversation to collaborators Feb 6, 2018
@eslint-deprecated eslint-deprecated bot added the archived due to age This issue has been archived; please open a new issue for any further discussion label Feb 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
archived due to age This issue has been archived; please open a new issue for any further discussion
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants