http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4958
Summary: sa-update doesn't recognize gpg on windows
Product: Spamassassin
Version: 3.1.3
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: normal
Priority: P5
Component: sa-update
AssignedTo: [email protected]
ReportedBy: [EMAIL PROTECTED]
The find_gpg_path sub needs some windows-specific code to properly find gpg in
the path. The modified sub is pasted below-- I realize that it'll need a check
for windows and a separate set of code to work in both *nix and windows. The two
lines that change are the split for the path which uses ; instead of : on
windows, and the catfile which needs the .exe on the end of gpg. Those were the
only changes.
sub find_gpg_path {
dbg("gpg: Searching for 'gpg' in ".$ENV{'PATH'});
my $path;
foreach my $dir (split(/;/, $ENV{'PATH'})) {
$dir = File::Spec->catfile($dir, 'gpg.exe');
if (-x $dir) {
$path = $dir;
last;
}
}
die "fatal: couldn't find GPG in \$PATH\n" unless ($path);
dbg("gpg: found $path");
return $path;
}
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.