Bug#820119: tidy reports valid NCR as invalid

"AYANOKOUZI, Ryuunosuke" <[email protected]>
Newsgroups gmane.linux.debian.devel.www
Message-ID <87vb3t7o43.wl-i38w7i3__43966.7932842442$1460022342$gmane$org@yahoo.co.jp>
Control: tag -1 + patch

Dear all,

At Wed, 6 Apr 2016 20:48:15 +0200,
Frank Lichtenheld wrote:
>
> 2016-04-06 18:52 GMT+02:00 victory <[email protected]>:
> > On Tue, 5 Apr 2016 20:16:53 +0200
> > Frank Lichtenheld wrote:
> >
> >> I assume you wanted to report this against tidy, not www.debian.org?
> >
> > if so, I always report to the upstream, not the debian's one
> >
> > see https://www-master.debian.org/build-logs/tidy/
> > files w/ 142bytes are caused by the issue
> > (other langs do not have the page [international/l10n/po/pl])
>
> Okay, that paragraph would have been helpful in the original mail to
> understand the contexts of your statement.

In HTML, "BREAK PERMITTED HERE" + "SPACE" can be rewritten by " ".
Because line break is automatically added by browser
between words separated by space.

How about apply this patch?
This patch replaces "&#130; " in translator's name to " ".
The patch is not fully tested, but I hope it will work.

Sincerely yours,
Ryuunosuke Ayanokouzi
--
AYANOKOUZI, Ryuunosuke <[email protected]>
fix_NCR_130.patch (application/octet-stream, 905 B)
Index: english/international/l10n/scripts/gen-files.pl
===================================================================
RCS file: /cvs/webwml/webwml/english/international/l10n/scripts/gen-files.pl,v
retrieving revision 1.96
diff -u -r1.96 gen-files.pl
--- english/international/l10n/scripts/gen-files.pl	7 Feb 2016 17:24:21 -0000	1.96
+++ english/international/l10n/scripts/gen-files.pl	7 Apr 2016 00:00:00 -0000
@@ -117,6 +117,11 @@
         $name =~ s/\s*<.*//;
         $name =~ s/&(?!#)/&amp;/g;
         $name =~ s/=\?.*?\?=//g;
+        my $regex = qr//;
+        # BREAK PERMITTED HERE (U+0082) is not allowed in HTML 4.01.
+        $regex = qr/(?:&#0*130;|&#x0*82;|\N{U+0082})/i;
+        $name =~ s/$regex(\s)/$1/g;
+        $name =~ s/(\s)$regex/$1/g;
         $name = 'DDTP' if $name eq 'Debian Description Translation Project';
         $name = '' if $name =~ m/\@/;
         return $name;
signature.asc (application/pgp-signature, 473 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAABAgAGBQJXBislAAoJECh1UQ+VhnAQxXkIAJuaKoRmT5Kk3rMSPZsi+O7T
MoTPv2Tu7RzPUmWQvMjqtq27YG26D3YddfoP7LEY18J/k2vford1BNXfofjEy/LR
d3Uf1F1sYVXmFxQSOPjxvmpl/K6ctSCt3F6hi9PRqxG+KtTJagfCsxrfKO/Qn/Ur
DhtFIexIxhq3XNIzoz6O0sWYHLk3Zq4lCiZULqnovJUIySUQp42nVCmgRUqp6pM9
fqopm5FegoFJtx+hWrhJOHTcgztmxdKVd6B+svpSSGf9m3C72OpjUF0GRDmjXUHp
cYo0AmyFxveKtDXnlth88p5v0PKj9u8P+FlfTck5lD8TUhNRVB/YWjaWR74FGNI=
=t5d+
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.