diff options
author | portix <portix@gmx.net> | 2012-03-19 01:26:52 +0100 |
---|---|---|
committer | portix <portix@gmx.net> | 2012-03-19 01:26:52 +0100 |
commit | e2b7d12a5bfb03cf1ff1af2f1c365463f15d1ec8 (patch) | |
tree | c1e5c5efe86c067796f5e5332b276e18ceec2f18 /src/util.c | |
parent | 1b8f946f592833a448a41879de9ec4f4727d2f39 (diff) | |
download | dwb-e2b7d12a5bfb03cf1ff1af2f1c365463f15d1ec8.zip |
Branch refactor: Use an anonymous, readonly object for hints
--HG--
branch : refactor
Diffstat (limited to 'src/util.c')
-rw-r--r-- | src/util.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -411,20 +411,20 @@ util_get_user_data_dir(const char *dir) { /* util_get_data_file(const char *filename) return: filename (alloc) or NULL {{{*/ char * -util_get_data_file(const char *filename) { +util_get_data_file(const char *filename, const char *dir) { if (filename == NULL) return NULL; char *path = NULL; char *ret = NULL; char *basename = g_path_get_basename(filename); - path = util_get_user_data_dir("lib"); + path = util_get_user_data_dir(dir); if (path != NULL) { ret = g_build_filename(path, basename, NULL); if (g_file_test(ret, G_FILE_TEST_EXISTS)) goto clean; } - path = util_get_system_data_dir("lib"); + path = util_get_system_data_dir(dir); if (path != NULL) { ret = g_build_filename(path, basename, NULL); if (g_file_test(ret, G_FILE_TEST_EXISTS)) |