Commit ce8155f7 authored by Joe Perches's avatar Joe Perches Committed by Linus Torvalds

get_maintainer: fix perl 5.22/5.24 deprecated/incompatible "\C" use

Perl 5.22 emits a deprecated message when "\C" is used in a regex.  Perl
5.24 will disallow it altogether.

Fix it by using [A-Z] instead of \C.
Signed-off-by: default avatarJoe Perches <joe@perches.com>
Reported-by: default avatarValdis Kletnieks <Valdis.Kletnieks@vt.edu>
Tested-by: default avatarValdis Kletnieks <Valdis.Kletnieks@vt.edu>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 364f68dc
...@@ -305,7 +305,7 @@ open (my $maint, '<', "${lk_path}MAINTAINERS") ...@@ -305,7 +305,7 @@ open (my $maint, '<', "${lk_path}MAINTAINERS")
while (<$maint>) { while (<$maint>) {
my $line = $_; my $line = $_;
if ($line =~ m/^(\C):\s*(.*)/) { if ($line =~ m/^([A-Z]):\s*(.*)/) {
my $type = $1; my $type = $1;
my $value = $2; my $value = $2;
...@@ -550,7 +550,7 @@ sub range_is_maintained { ...@@ -550,7 +550,7 @@ sub range_is_maintained {
for (my $i = $start; $i < $end; $i++) { for (my $i = $start; $i < $end; $i++) {
my $line = $typevalue[$i]; my $line = $typevalue[$i];
if ($line =~ m/^(\C):\s*(.*)/) { if ($line =~ m/^([A-Z]):\s*(.*)/) {
my $type = $1; my $type = $1;
my $value = $2; my $value = $2;
if ($type eq 'S') { if ($type eq 'S') {
...@@ -568,7 +568,7 @@ sub range_has_maintainer { ...@@ -568,7 +568,7 @@ sub range_has_maintainer {
for (my $i = $start; $i < $end; $i++) { for (my $i = $start; $i < $end; $i++) {
my $line = $typevalue[$i]; my $line = $typevalue[$i];
if ($line =~ m/^(\C):\s*(.*)/) { if ($line =~ m/^([A-Z]):\s*(.*)/) {
my $type = $1; my $type = $1;
my $value = $2; my $value = $2;
if ($type eq 'M') { if ($type eq 'M') {
...@@ -617,7 +617,7 @@ sub get_maintainers { ...@@ -617,7 +617,7 @@ sub get_maintainers {
for ($i = $start; $i < $end; $i++) { for ($i = $start; $i < $end; $i++) {
my $line = $typevalue[$i]; my $line = $typevalue[$i];
if ($line =~ m/^(\C):\s*(.*)/) { if ($line =~ m/^([A-Z]):\s*(.*)/) {
my $type = $1; my $type = $1;
my $value = $2; my $value = $2;
if ($type eq 'X') { if ($type eq 'X') {
...@@ -632,7 +632,7 @@ sub get_maintainers { ...@@ -632,7 +632,7 @@ sub get_maintainers {
if (!$exclude) { if (!$exclude) {
for ($i = $start; $i < $end; $i++) { for ($i = $start; $i < $end; $i++) {
my $line = $typevalue[$i]; my $line = $typevalue[$i];
if ($line =~ m/^(\C):\s*(.*)/) { if ($line =~ m/^([A-Z]):\s*(.*)/) {
my $type = $1; my $type = $1;
my $value = $2; my $value = $2;
if ($type eq 'F') { if ($type eq 'F') {
...@@ -933,7 +933,7 @@ sub find_first_section { ...@@ -933,7 +933,7 @@ sub find_first_section {
while ($index < @typevalue) { while ($index < @typevalue) {
my $tv = $typevalue[$index]; my $tv = $typevalue[$index];
if (($tv =~ m/^(\C):\s*(.*)/)) { if (($tv =~ m/^([A-Z]):\s*(.*)/)) {
last; last;
} }
$index++; $index++;
...@@ -947,7 +947,7 @@ sub find_starting_index { ...@@ -947,7 +947,7 @@ sub find_starting_index {
while ($index > 0) { while ($index > 0) {
my $tv = $typevalue[$index]; my $tv = $typevalue[$index];
if (!($tv =~ m/^(\C):\s*(.*)/)) { if (!($tv =~ m/^([A-Z]):\s*(.*)/)) {
last; last;
} }
$index--; $index--;
...@@ -961,7 +961,7 @@ sub find_ending_index { ...@@ -961,7 +961,7 @@ sub find_ending_index {
while ($index < @typevalue) { while ($index < @typevalue) {
my $tv = $typevalue[$index]; my $tv = $typevalue[$index];
if (!($tv =~ m/^(\C):\s*(.*)/)) { if (!($tv =~ m/^([A-Z]):\s*(.*)/)) {
last; last;
} }
$index++; $index++;
...@@ -987,7 +987,7 @@ sub get_maintainer_role { ...@@ -987,7 +987,7 @@ sub get_maintainer_role {
for ($i = $start + 1; $i < $end; $i++) { for ($i = $start + 1; $i < $end; $i++) {
my $tv = $typevalue[$i]; my $tv = $typevalue[$i];
if ($tv =~ m/^(\C):\s*(.*)/) { if ($tv =~ m/^([A-Z]):\s*(.*)/) {
my $ptype = $1; my $ptype = $1;
my $pvalue = $2; my $pvalue = $2;
if ($ptype eq "S") { if ($ptype eq "S") {
...@@ -1046,7 +1046,7 @@ sub add_categories { ...@@ -1046,7 +1046,7 @@ sub add_categories {
for ($i = $start + 1; $i < $end; $i++) { for ($i = $start + 1; $i < $end; $i++) {
my $tv = $typevalue[$i]; my $tv = $typevalue[$i];
if ($tv =~ m/^(\C):\s*(.*)/) { if ($tv =~ m/^([A-Z]):\s*(.*)/) {
my $ptype = $1; my $ptype = $1;
my $pvalue = $2; my $pvalue = $2;
if ($ptype eq "L") { if ($ptype eq "L") {
...@@ -1088,7 +1088,7 @@ sub add_categories { ...@@ -1088,7 +1088,7 @@ sub add_categories {
if ($name eq "") { if ($name eq "") {
if ($i > 0) { if ($i > 0) {
my $tv = $typevalue[$i - 1]; my $tv = $typevalue[$i - 1];
if ($tv =~ m/^(\C):\s*(.*)/) { if ($tv =~ m/^([A-Z]):\s*(.*)/) {
if ($1 eq "P") { if ($1 eq "P") {
$name = $2; $name = $2;
$pvalue = format_email($name, $address, $email_usename); $pvalue = format_email($name, $address, $email_usename);
...@@ -1105,7 +1105,7 @@ sub add_categories { ...@@ -1105,7 +1105,7 @@ sub add_categories {
if ($name eq "") { if ($name eq "") {
if ($i > 0) { if ($i > 0) {
my $tv = $typevalue[$i - 1]; my $tv = $typevalue[$i - 1];
if ($tv =~ m/^(\C):\s*(.*)/) { if ($tv =~ m/^([A-Z]):\s*(.*)/) {
if ($1 eq "P") { if ($1 eq "P") {
$name = $2; $name = $2;
$pvalue = format_email($name, $address, $email_usename); $pvalue = format_email($name, $address, $email_usename);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment