This commit is contained in:
yuin 2021-09-11 12:44:01 +09:00
parent a8ed3c4205
commit 97df31c2ec
2 changed files with 9 additions and 1 deletions

View file

@ -456,3 +456,11 @@ x
<p>&amp;#x0000041;</p>
//= = = = = = = = = = = = = = = = = = = = = = = =//
33: \x01 should be escaped all the time
OPTIONS: {"enableEscape": true}
//- - - - - - - - -//
[x](\x01)
//- - - - - - - - -//
<p><a href="%01">x</a></p>
//= = = = = = = = = = = = = = = = = = = = = = = =//

View file

@ -709,7 +709,7 @@ func URLEscape(v []byte, resolveReference bool) []byte {
n = i
continue
}
if int(u8len) >= len(v) {
if int(u8len) > len(v) {
u8len = int8(len(v) - 1)
}
if u8len == 0 {