spamassassin-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Malte S. Stretz" <>
Subject Re: svn commit: r106600 - /spamassassin/trunk/t/
Date Fri, 26 Nov 2004 20:50:52 GMT
On Friday 26 November 2004 21:42 CET Sidney Markowitz wrote:
> Malte S. Stretz wrote:
> > So maybe we should add a M::SA::Util::get_home() which first
> > tries $ENV{HOME}, then on Windows $ENV{HOMEDRIVE}\$ENV{HOMEDIR}, then
> > portable_getpwuid()[7], then... foo?
> portable_getpwuid() doesn't seem to do anything useful under Windows for
> this purpose and shouldn't be needed anyway. It just returns 'unknown'
> for the name, which works when you don't care about the actual user name.

Yeah, noticed that, too.

> The first two steps are fine, and probably enough, except that you would
>    not have to add the '\' separator, it is already in HOMEDIR.
> Question: In does everything work if that is what it
> uses for HOME or does anything have to be done to convert \ to / ?

What do you think about the attached patch?  Try it with
perl -Ilib -MMail::SpamAssassin::Util \
  -le 'print Mail::SpamAssassin::Util::get_home()'


[SGT] Simon G. Tatham: "How to Report Bugs Effectively"
[ESR] Eric S. Raymond: "How To Ask Questions The Smart Way"

View raw message