[Scummvm-git-logs] scummvm-tools master -> 44b57ca445cc075e67d67b2a15c0b0a8c4b52cf0

sev- sev at scummvm.org
Mon Mar 9 17:52:04 UTC 2020


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm-tools' repo located at https://github.com/scummvm/scummvm-tools .

Summary:
44b57ca445 PRINCE: Implement prefx sanity check for .po parsing


Commit: 44b57ca445cc075e67d67b2a15c0b0a8c4b52cf0
    https://github.com/scummvm/scummvm-tools/commit/44b57ca445cc075e67d67b2a15c0b0a8c4b52cf0
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-03-09T18:51:26+01:00

Commit Message:
PRINCE: Implement prefx sanity check for .po parsing

Changed paths:
    engines/prince/po-parse.pl


diff --git a/engines/prince/po-parse.pl b/engines/prince/po-parse.pl
index aa628ebff..14e4bc64b 100644
--- a/engines/prince/po-parse.pl
+++ b/engines/prince/po-parse.pl
@@ -92,6 +92,15 @@ for my $f (keys %data) {
 	for my $k (keys %{$data{$f}}) {
 		if (not exists $data1{$f}{$k}) {
 			warn "Missing msgstr $f:$k";
+		} else {
+			my $pref1;
+			my $pref2;
+			($pref1) = ($data{$f}{$k} =~ /^([P#HEROT1234567890\$]+:)/);
+			($pref2) = ($data1{$f}{$k} =~ /^([P#HEROT1234567890\$]+:)/);
+
+			if ($pref1 cmp $pref2) {
+				warn "Incorrect prefix in $f:$k: $pref1 != $pref2";
+			}
 		}
 	}
 }




More information about the Scummvm-git-logs mailing list