forked from len0rd/rockbox
updatelang: Expand suspicius character tests.
* dest: < > * voice: [ ] < > { } Change-Id: I97701e52807db996037b7542fb0b01f9db0dbc0f
This commit is contained in:
parent
7d9fbae749
commit
24ae4aee33
1 changed files with 4 additions and 4 deletions
|
@ -402,9 +402,9 @@ foreach my $id (@langorder) {
|
||||||
|
|
||||||
my $sane = $lang{$id}{'dest'}{$tgt};
|
my $sane = $lang{$id}{'dest'}{$tgt};
|
||||||
$sane =~ s/^~?(.*)/$1/; # Strip off leading ~ if it's there as it's not a legal character otherwise
|
$sane =~ s/^~?(.*)/$1/; # Strip off leading ~ if it's there as it's not a legal character otherwise
|
||||||
if ($sane =~ tr/"~//) {
|
if ($sane =~ tr/"~<>//) {
|
||||||
# If it has suspicious characters that are not allowed
|
# If it has suspicious characters that are not allowed
|
||||||
$lang{$id}{'notes'} .= "### The <dest> section for '$id:$tgt' has some suspicious characters (eg '~'), please double-check!\n";
|
$lang{$id}{'notes'} .= "### The <dest> section for '$id:$tgt' has some suspicious characters (eg \",~,<,>), please double-check!\n";
|
||||||
# print "#!! '$id:$tgt' suspicious characters\n";
|
# print "#!! '$id:$tgt' suspicious characters\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -476,9 +476,9 @@ foreach my $id (@langorder) {
|
||||||
}
|
}
|
||||||
my $sane = $lang{$id}{'voice'}{$tgt};
|
my $sane = $lang{$id}{'voice'}{$tgt};
|
||||||
$sane =~ s/^~?(.*)/$1/; # Strip off leading ~ if it's there as it's not a legal character otherwise
|
$sane =~ s/^~?(.*)/$1/; # Strip off leading ~ if it's there as it's not a legal character otherwise
|
||||||
if ($sane =~ tr/%"~://) {
|
if ($sane =~ tr/%"~:\[\]<>{}//) {
|
||||||
# Suspicious characters that are not typically voiced..
|
# Suspicious characters that are not typically voiced..
|
||||||
$lang{$id}{'notes'} .= "### The <voice> section for '$id:$tgt' has some suspicious characters (eg '%' or '~' or ':'), please correct!\n";
|
$lang{$id}{'notes'} .= "### The <voice> section for '$id:$tgt' has some suspicious characters (eg %,\",~,:,<,>,[,],{,}), please correct!\n";
|
||||||
# print "#!! '$id:$tgt' suspicious characters\n";
|
# print "#!! '$id:$tgt' suspicious characters\n";
|
||||||
}
|
}
|
||||||
if ($lang{$id}{'voice'}{$tgt} =~ /\.\.\./) {
|
if ($lang{$id}{'voice'}{$tgt} =~ /\.\.\./) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue