Add process to make parent dir if isn't
This commit is contained in:
parent
0377be5f81
commit
f73a4bb453
|
@ -1029,6 +1029,11 @@ static void init()
|
|||
gchar *path = g_build_filename(
|
||||
g_get_user_config_dir(), APPNAME, "easylist.txt", NULL);
|
||||
|
||||
char *dir = g_path_get_dirname(path);
|
||||
if (!g_file_test(dir, G_FILE_TEST_EXISTS))
|
||||
g_mkdir_with_parents(dir, 0700);
|
||||
g_free(dir);
|
||||
|
||||
GFile *gf = g_file_new_for_path(path);
|
||||
GFileMonitor *gm = g_file_monitor_file(gf,
|
||||
G_FILE_MONITOR_NONE, NULL, NULL);
|
||||
|
|
Loading…
Reference in New Issue
Block a user