On Friday 26 November 2004 21:13 CET Theo Van Dinter wrote:
> On Fri, Nov 26, 2004 at 09:08:53PM +0100, Malte S. Stretz wrote:
> > Hm. The line is
> > $path =~ s!^~/!$ENV{'HOME'}/!;
> > so probably HOME is not set. The question is, what should this routine
> > do if HOME is not set; probably the value from (getpwuid($<))[7]
> > (before $< is changed). What does getpwuid() say on Windows?
>
> Doesn't matter really, we use M::SA::Util::portable_getpwuid() ... :)
Ah, cool :) 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?
Cheers,
Malte
--
[SGT] Simon G. Tatham: "How to Report Bugs Effectively"
<http://www.chiark.greenend.org.uk/~sgtatham/bugs.html>
[ESR] Eric S. Raymond: "How To Ask Questions The Smart Way"
<http://www.catb.org/~esr/faqs/smart-questions.html>