}
sub processbdf ($$$$) {
- my ($inbdf,$outbdf,$logfile,$what) = @_;
+ my ($inbdf,$outbdf,$logfh,$what) = @_;
my $state='idle';
my ($foundry,$font);
my ($w,$h,$xo,$yo,$y,$bitmap,$glyph);
return 'no bdf data' # also special cased in processpcfgz
if !$anyinput;
if ($modified) {
- printf $logfile "%s: %d glyphs changed\n", $what, $modified
+ printf $logfh "%s: %d glyphs changed\n", $what, $modified
or die $!;
} else {
- printf $logfile "%s: unchanged - no rules matched\n", $what
+ printf $logfh "%s: unchanged - no rules matched\n", $what
or die $!;
}
return $modified;
}
sub processpcfgz ($$$$) {
- my ($inpcfgz,$outpcfgz,$logfile,$what) = @_;
+ my ($inpcfgz,$outpcfgz,$logfh,$what) = @_;
print $reportfh "processing $inpcfgz to $outpcfgz\n" if $verbose>=2;
my $current = new IO::File $inpcfgz, '<' or die "$inpcfgz $!";
my ($usread,$uswrite);
$current = $reader;
}
}
- my $r = processbdf($usread,$uswrite,$logfile,$what);
+ my $r = processbdf($usread,$uswrite,$logfh,$what);
my $none = $r !~ m/^\d/;
$ch{'gunzip'}{SigOK}{13} = 1;
my $logpath = "$fontdir/$logfile";
unlink "$logpath" or $!==&ENOENT or die "$logpath $!";
- my $log = new IO::File $logpath, ">>" or die "$logpath $!";
+ my $logfh = new IO::File $logpath, ">>" or die "$logpath $!";
if (!$wanted_parallel) {
$wanted_parallel = Sys::CPU::cpu_count();
if (!$child) {
my $r = processpcfgz("$fontdir/$dent",
"$fontdir/$outdent.new",
- $log, $dent);
+ $logfh, $dent);
my $rc;
if ($r !~ m/^\d/) {
- printf $log "%s: unchanged - %s\n", $dent, $r;
+ printf $logfh "%s: unchanged - %s\n", $dent, $r;
unlink "$fontdir/$outdent.new" or die "$fontdir $outdent $!";
$rc = 2;
} else {
or die "$fontdir $outdent $!";
$rc = 0;
}
- $log->flush or die "$logpath $!";
+ $logfh->flush or die "$logpath $!";
exit $rc;
}
$inprogress{$child} = {