mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Change the searchpath separator to glib macro so that on Windows, ';' is used. Also clean up more path creation functions.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@14777 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
e01902ba2f
commit
bdd7cfe24e
@ -667,8 +667,7 @@ gnc_file_be_remove_old_files(FileBackend *be)
|
||||
if (gnc_file_be_select_files (dent) == 0)
|
||||
continue;
|
||||
|
||||
/* G_DIR_SEPARATOR_S is "/" on unix and "\\" on windows. */
|
||||
name = g_strconcat(be->dirname, G_DIR_SEPARATOR_S, dent->d_name, NULL);
|
||||
name = g_build_filename(be->dirname, dent->d_name, (char*)NULL);
|
||||
len = strlen(name) - 4;
|
||||
|
||||
/* Is this file associated with the current data file */
|
||||
|
@ -87,7 +87,8 @@ gnc_module_system_search_dirs(void)
|
||||
break;
|
||||
#endif
|
||||
|
||||
case ':':
|
||||
/* This is ':' on UNIX machines and ';' under Windows. */
|
||||
case G_SEARCHPATH_SEPARATOR:
|
||||
if(!escchar)
|
||||
{
|
||||
list = g_list_append(list, token->str);
|
||||
@ -228,9 +229,8 @@ gnc_module_system_refresh(void)
|
||||
{
|
||||
/* get the full path name, then dlopen the library and see
|
||||
* if it has the appropriate symbols to be a gnc_module */
|
||||
fullpath = g_strdup_printf("%s" G_DIR_SEPARATOR_S "%s", (char *)(current->data),
|
||||
dent->d_name);
|
||||
/* G_DIR_SEPARATOR_S is "/" on unix and "\\" on windows. */
|
||||
fullpath = g_build_filename((const gchar *)(current->data),
|
||||
dent->d_name, (char*)NULL);
|
||||
info = gnc_module_get_info(fullpath);
|
||||
|
||||
if(info)
|
||||
|
Loading…
Reference in New Issue
Block a user