From 38eef72722a185273aeaeaac83faa3b99c8dad00 Mon Sep 17 00:00:00 2001 From: Not Zed Date: Wed, 5 Feb 2003 04:47:03 +0000 Subject: re-enable. (prepare_importer_page): re-enable importer code. 2003-02-05 Not Zed * e-shell-startup-wizard.c (start_importers): re-enable. (prepare_importer_page): re-enable importer code. * e-shell-importer.c (druid_finish_button_change): removed, since its not such a hack to change anymore. Dunno how to get an icon on it tho, without a stock button. (show_import_wizard): Change the apply button to "Import" here. 2003-01-28 Not Zed * e-local-storage.c (create_folder_directory): We can't use pointer arithmetic with g_path_get_*, so adjust code accordingly. 2003-01-16 Not Zed * e-shell-startup-wizard.c (e_shell_startup_wizard_create): Hook onto finish instead of next on the last page. svn path=/trunk/; revision=19753 --- shell/e-local-storage.c | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'shell/e-local-storage.c') diff --git a/shell/e-local-storage.c b/shell/e-local-storage.c index 4de766b09e..3b5d3fa86a 100644 --- a/shell/e-local-storage.c +++ b/shell/e-local-storage.c @@ -342,7 +342,7 @@ create_folder_directory (ELocalStorage *local_storage, { EStorage *storage; ELocalStoragePrivate *priv; - char *folder_name; + char *parent_path; char *physical_path; storage = E_STORAGE (local_storage); @@ -351,17 +351,16 @@ create_folder_directory (ELocalStorage *local_storage, *physical_path_return = NULL; g_assert (g_path_is_absolute (path)); - folder_name = g_path_get_basename (path); + parent_path = g_path_get_dirname(path); - if (folder_name != path + 1) { + if (strlen(parent_path) > 1) { char *subfolders_directory_physical_path; - char *parent_path; - + char *parent; + /* Create the `subfolders' subdirectory under the parent. */ - - parent_path = g_strndup (path, folder_name - path); - subfolders_directory_physical_path = e_path_to_physical (priv->base_path, parent_path); - g_free (parent_path); + parent = alloca(strlen(parent_path)+2); + sprintf(parent, "%s/", parent_path); + subfolders_directory_physical_path = e_path_to_physical (priv->base_path, parent); if (! g_file_test (subfolders_directory_physical_path, G_FILE_TEST_EXISTS)) { if (mkdir (subfolders_directory_physical_path, 0700) == -1) { @@ -372,7 +371,7 @@ create_folder_directory (ELocalStorage *local_storage, g_free (subfolders_directory_physical_path); } - g_free (folder_name); + g_free (parent_path); physical_path = e_path_to_physical (priv->base_path, path); -- cgit v1.2.3