After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 354973 - g_get_home_dir() wrongfully used in test-resolve-file-path.c
g_get_home_dir() wrongfully used in test-resolve-file-path.c
Status: VERIFIED OBSOLETE
Product: GnuCash
Classification: Other
Component: Engine
2.0.x
Other All
: Normal enhancement
: ---
Assigned To: Derek Atkins
Derek Atkins
Depends on:
Blocks:
 
 
Reported: 2006-09-08 14:33 UTC by Olivier Crête
Modified: 2018-06-29 21:12 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch to replace g_get_home_dir() with getenv("HOME") in the test (1.20 KB, patch)
2006-09-08 14:34 UTC, Olivier Crête
none Details | Review

Description Olivier Crête 2006-09-08 14:33:16 UTC
Please describe the problem:
g_get_home_dir() will rely on the content of passwd before HOME, while the xacc* function uses HOME

Steps to reproduce:
HOME=$(pwd) ./test-resolve-file-path.c

Actual results:


Expected results:


Does this happen every time?


Other information:
I'm attaching a patch that just replaces the glib function with a direct use of HOME... Maybe the opposite should be done and use g_get_home_dir() in the xacc* function.
Comment 1 Olivier Crête 2006-09-08 14:34:12 UTC
Created attachment 72414 [details] [review]
patch to replace g_get_home_dir() with getenv("HOME") in the test
Comment 2 Christian Stimming 2006-09-11 09:11:22 UTC
getenv("HOME") has been replaced by g_get_home_dir() intentionally  in 
http://svn.gnucash.org/trac/changeset/12025

What is the problem with g_get_home_dir? In any case we are talking about a *test* here, so we're open for proposals that apply to tests but not the actual program runtime. 
Comment 3 Olivier Crête 2006-09-11 18:27:00 UTC
The current SVN seems ok since changeset 14543 where the getenv call was replaced with g_get_home_dir().
If you want to be certain you can try:
HOME=. ./test-resolve-file-path
Comment 4 John Ralls 2018-06-29 21:12:30 UTC
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=354973. Please update any external references or bookmarks.