diff --git a/lib/marked.js b/lib/marked.js index 15ad63bfe7..eabf99eedb 100644 --- a/lib/marked.js +++ b/lib/marked.js @@ -691,7 +691,7 @@ InlineLexer.prototype.output = function(src) { // escape if (cap = this.rules.escape.exec(src)) { src = src.substring(cap[0].length); - out += cap[1]; + out += escape(cap[1]); continue; } diff --git a/test/new/escaped_angles.html b/test/new/escaped_angles.html index 7cf47c49ee..aa3e73a465 100644 --- a/test/new/escaped_angles.html +++ b/test/new/escaped_angles.html @@ -1 +1 @@ -

>

+

>

diff --git a/test/original/backslash_escapes.html b/test/original/backslash_escapes.html index 29870dac5d..7241d11fa4 100644 --- a/test/original/backslash_escapes.html +++ b/test/original/backslash_escapes.html @@ -20,7 +20,7 @@

Right paren: )

-

Greater-than: >

+

Greater-than: >

Hash: #

diff --git a/test/specs/commonmark/commonmark-spec.js b/test/specs/commonmark/commonmark-spec.js index 5b62131134..4d3550dae1 100644 --- a/test/specs/commonmark/commonmark-spec.js +++ b/test/specs/commonmark/commonmark-spec.js @@ -293,7 +293,7 @@ describe('CommonMark 0.28 Backslash escapes', function() { var section = 'Backslash escapes'; // var shouldPassButFails = []; - var shouldPassButFails = [291, 300, 301]; + var shouldPassButFails = [300, 301]; var willNotBeAttemptedByCoreTeam = [];