]> Sergey Matveev's repositories - public-inbox.git/commit
www: diff: fix encoding problems when showing diff
authorEric Wong <e@80x24.org>
Tue, 31 Jan 2023 10:31:57 +0000 (10:31 +0000)
committerEric Wong <e@80x24.org>
Tue, 31 Jan 2023 10:38:56 +0000 (10:38 +0000)
commit402234aa4eaf4732e5e1636099115465ec6e5c15
treec8f5a9418eb62e750d309b4c97ead7ea6574af0d
parent0746680da02f51ff3f85ebde1a3e9219d0946cf0
www: diff: fix encoding problems when showing diff

We need to use the utf8 layer when writing files to be diffed,
and utf8::decode the `git diff' output.  Furthermore, do the
CRLF > LF conversion early to avoid showing CRLF vs LF
differences in the diff, since that doesn't matter to MUAs
(nor our normal HTML views)
lib/PublicInbox/MailDiff.pm
t/psgi_v2.t