From c4862fd9c181dc359e983547972d7670c97fba51 Mon Sep 17 00:00:00 2001 From: Tatsuya Kinoshita Date: Mon, 16 Jan 2023 06:08:57 +0900 Subject: [PATCH] Add GROFF_NO_SGR=1 to w3mman2html.cgi for non-Debian groff Bug-Debian: https://github.com/tats/w3m/pull/238 Bug-Debian: https://github.com/tats/w3m/issues/201 --- scripts/w3mman/w3mman2html.cgi.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/w3mman/w3mman2html.cgi.in b/scripts/w3mman/w3mman2html.cgi.in index 2d326a9..59af785 100644 --- a/scripts/w3mman/w3mman2html.cgi.in +++ b/scripts/w3mman/w3mman2html.cgi.in @@ -81,7 +81,7 @@ if ($query{"local"}) { if (! ($file =~ /^\//)) { $file = $query{"pwd"} . '/' . $file; } - open(F, "MAN_KEEP_FORMATTING=1 $MAN $file 2> /dev/null |"); + open(F, "GROFF_NO_SGR=1 MAN_KEEP_FORMATTING=1 $MAN $file 2> /dev/null |"); } else { $man = $query{"man"}; if ($man =~ s/\((\w+)\)$//) { @@ -97,7 +97,7 @@ if ($query{"local"}) { $section =~ s:([^-\w\200-\377.,])::g; $man =~ s:([^-\w\200-\377.,])::g; - open(F, "MAN_KEEP_FORMATTING=1 $MAN $section $man 2> /dev/null |"); + open(F, "GROFF_NO_SGR=1 MAN_KEEP_FORMATTING=1 $MAN $section $man 2> /dev/null |"); } $ok = 0; undef $header;