about summary refs log tree commit homepage
path: root/lib/PublicInbox/RepobrowseGitPatch.pm
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2016-01-18 23:44:40 +0000
committerEric Wong <e@80x24.org>2016-04-05 18:58:27 +0000
commit66ad0a45c58ed63ec16a35f41f3eda7cb8917c50 (patch)
tree2509177a625278adec3ae7c64a4c367757f97e58 /lib/PublicInbox/RepobrowseGitPatch.pm
parentfa8e2e7e001d7585d6e41c254ee4443a1672bca5 (diff)
downloadpublic-inbox-66ad0a45c58ed63ec16a35f41f3eda7cb8917c50.tar.gz
We'll be UTF-8 imperialists for now and assume all of our
textual output is UTF-8 for the benefit of browsers.
Diffstat (limited to 'lib/PublicInbox/RepobrowseGitPatch.pm')
-rw-r--r--lib/PublicInbox/RepobrowseGitPatch.pm3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/PublicInbox/RepobrowseGitPatch.pm b/lib/PublicInbox/RepobrowseGitPatch.pm
index 4cb05960..b67fb86f 100644
--- a/lib/PublicInbox/RepobrowseGitPatch.pm
+++ b/lib/PublicInbox/RepobrowseGitPatch.pm
@@ -33,7 +33,8 @@ sub call_git_patch {
         return unless (defined $n && $n > 0);
         sub {
                 my ($res) = @_; # Plack callback
-                my $fh = $res->([200, ['Content-Type' => 'text/plain']]);
+                my $fh = $res->([200, [
+                        'Content-Type' => 'text/plain; charset=UTF-8']]);
                 $fh->write($buf);
                 while (1) {
                         $n = read($fp, $buf, 8192);