]> git.donarmstrong.com Git - debbugs.git/commitdiff
include non-breaking spaces in pheader regex for old perl (≤5.18)
authorDon Armstrong <don@donarmstrong.com>
Sat, 5 Aug 2017 15:32:32 +0000 (08:32 -0700)
committerDon Armstrong <don@donarmstrong.com>
Sat, 5 Aug 2017 15:32:32 +0000 (08:32 -0700)
scripts/process

index 228d28ad32fc6166e8c52b9cd025aa0fdbfe8d32..38e4f90c8c1a1e326b5530d8bed341ba29f9a109 100755 (executable)
@@ -225,7 +225,10 @@ for my $phline (@bodylines)
     # Fixes #488554
     $phline =~ s/\xef\xbb\xbf//g;
     $phline =~ s/\N{U+FEFF}//g;
-    last if $phline !~ m/^([\w-]+):\s*(\S.*)/;
+    last if $phline !~ m/^([\w-]+): # psuedoheader
+                        (?:\s|\N{U+00A0})* # zero or more spaces, including
+                                            # non-breaking space
+                        (\S.*)/x; # pseudoheader value
     my ($fn, $fv) = ($1, $2);
     $fv =~ s/\s*$//;
     # pluralize tag/usertag