Skip to content

Commit a587a28

Browse files
authored
Fix another clusterfuzz identified issue (#15096)
* Fix another clusterfuzz identified issue Signed-off-by: Andrew Thornton <[email protected]>
1 parent e6377d5 commit a587a28

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/markup/html.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@ func (ctx *postProcessCtx) postProcess(rawHTML []byte) ([]byte, error) {
327327
_, _ = res.WriteString("<html><body>")
328328

329329
// Strip out nuls - they're always invalid
330-
_, _ = nulCleaner.WriteString(res, string(tagCleaner.ReplaceAll(rawHTML, []byte("&lt;$1"))))
330+
_, _ = res.Write(tagCleaner.ReplaceAll([]byte(nulCleaner.Replace(string(rawHTML))), []byte("&lt;$1")))
331331

332332
// close the tags
333333
_, _ = res.WriteString("</body></html>")

0 commit comments

Comments
 (0)