From 9daf2bcb8486b15d2c2579cc8d08aa23e9b73e6e Mon Sep 17 00:00:00 2001 From: Ashe Connor Date: Wed, 5 Sep 2018 11:34:59 +1000 Subject: [PATCH 1/2] test --- test/regression.txt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/regression.txt b/test/regression.txt index 0569b3617..87c0107ef 100644 --- a/test/regression.txt +++ b/test/regression.txt @@ -169,3 +169,11 @@ This ~text~~~~ is ~~~~curious~. .

This text is curious.

```````````````````````````````` + +`~` should not be escaped in href — https://github.com/github/markup/issues/311 + +```````````````````````````````` example +[x](http://members.aon.at/~nkehrer/ibm_5110/emu5110.html) +. +

x

+```````````````````````````````` From 182e2684411744ce08e46abdaceb92e693d64382 Mon Sep 17 00:00:00 2001 From: Ashe Connor Date: Wed, 5 Sep 2018 11:36:58 +1000 Subject: [PATCH 2/2] fix: do not percent-encode ~ --- src/houdini_href_e.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/houdini_href_e.c b/src/houdini_href_e.c index 9152803df..8c38d2fb9 100644 --- a/src/houdini_href_e.c +++ b/src/houdini_href_e.c @@ -7,7 +7,7 @@ /* * The following characters will not be escaped: * - * -_.+!*'(),%#@?=;:/,+&$ alphanum + * -_.+!*'(),%#@?=;:/,+&$~ alphanum * * Note that this character set is the addition of: * @@ -35,7 +35,7 @@ static const char HREF_SAFE[] = { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,