FAILURE xaccResolveFilePath test-resolve-file-path.c:81
Derek Atkins
warlord at MIT.EDU
Mon Sep 25 08:12:50 EDT 2006
Christian Stimming <stimming at tuhh.de> writes:
> Isn't this directly caused by the "sudo" part of "make check"? Because
> obviously /home/umike/ and /root/ somehow get confused with each other here.
> I changed the method of determining the home directory some months ago.
> Before it was looked up by getenv("HOME"), but now the glib function
> g_get_home_dir() will use /etc/passwd in higher precedence. The glib docs
> even say "Note that in contrast to traditional Unix tools, this function
> prefers passwd entries over the HOME environment variable."
>
> The switch from getenv() to g_get_home_dir() was necessary because on non-Unix
> systems (i.e. Windows) we cannot rely on the env variable HOME for a useful,
> user-specific home directory. Using the function offered by glib and having
> glib take care of portability seemd like the easy solution to this.
Perhaps we should use something like:
homedir = getenv("HOME")
if (!homedir)
homedir = g_get_home_dir();
> Christian
-derek
--
Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
Member, MIT Student Information Processing Board (SIPB)
URL: http://web.mit.edu/warlord/ PP-ASEL-IA N1NWH
warlord at MIT.EDU PGP key available
More information about the gnucash-devel
mailing list