[Gnucash-changes] r12024 - gnucash/trunk/src/app-utils - Consolidate the creation of all file names under ~/.gnucash, and also

David Hampton hampton at cvs.gnucash.org
Wed Nov 23 17:41:22 EST 2005


Author: hampton
Date: 2005-11-23 17:41:21 -0500 (Wed, 23 Nov 2005)
New Revision: 12024
Trac: http://svn.gnucash.org/trac/changeset/12024

Modified:
   gnucash/trunk/src/app-utils/file-utils.c
Log:
Consolidate the creation of all file names under ~/.gnucash, and also
the checks for the existence of ~/.gnucash and ~/.gnucash/books.  Add
better error messages when there is a problem.


Modified: gnucash/trunk/src/app-utils/file-utils.c
===================================================================
--- gnucash/trunk/src/app-utils/file-utils.c	2005-11-23 22:40:03 UTC (rev 12023)
+++ gnucash/trunk/src/app-utils/file-utils.c	2005-11-23 22:41:21 UTC (rev 12024)
@@ -32,6 +32,7 @@
 
 #include "file-utils.h"
 #include "gnc-engine.h"
+#include "gnc-filepath-utils.h"
 #include "gnc-gkeyfile-utils.h"
  
 /* This static indicates the debugging module that this .o belongs to.  */
@@ -186,8 +187,7 @@
 
   basename = g_path_get_basename(url);
   DEBUG("Basename %s", basename);
-  original = g_build_filename(g_get_home_dir(), ".gnucash",
-			      "books", basename, NULL);
+  original = gnc_build_book_path(basename);
   g_free(basename);
   DEBUG("Original %s", original);
 



More information about the gnucash-changes mailing list