diff options
author | JP Rosevear <jpr@ximian.com> | 2004-01-27 06:00:10 +0800 |
---|---|---|
committer | JP Rosevear <jpr@src.gnome.org> | 2004-01-27 06:00:10 +0800 |
commit | a0c4af714ebbe37f729398dd0ee24f9a7854d947 (patch) | |
tree | f352bb4f503e20121633a7cb46d817f9b5037ae9 /e-util/e-folder-map.c | |
parent | 8c939dca8ad71ce10c7758243385b12bced22449 (diff) | |
download | gsoc2013-evolution-a0c4af714ebbe37f729398dd0ee24f9a7854d947.tar.gz gsoc2013-evolution-a0c4af714ebbe37f729398dd0ee24f9a7854d947.tar.zst gsoc2013-evolution-a0c4af714ebbe37f729398dd0ee24f9a7854d947.zip |
use g_file_test instead of stat and pass the type e_folder_map_dir when
2004-01-26 JP Rosevear <jpr@ximian.com>
* e-folder-map.c (e_folder_map_dir): use g_file_test instead of
stat and pass the type e_folder_map_dir when recursing
svn path=/trunk/; revision=24449
Diffstat (limited to 'e-util/e-folder-map.c')
-rw-r--r-- | e-util/e-folder-map.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/e-util/e-folder-map.c b/e-util/e-folder-map.c index fd845a4b48..8643152a06 100644 --- a/e-util/e-folder-map.c +++ b/e-util/e-folder-map.c @@ -93,7 +93,6 @@ e_folder_map_dir (const char *dirname, const char *type, GSList **dir_list) { char *path; const char *name; - struct stat st; GDir *dir; GError *error = NULL; @@ -116,7 +115,7 @@ e_folder_map_dir (const char *dirname, const char *type, GSList **dir_list) try_subdirs: path = g_build_filename (dirname, "subfolders", NULL); - if (stat (path, &st) == -1 || !S_ISDIR (st.st_mode)) { + if (!g_file_test (path, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_DIR)) { g_free (path); return; } @@ -140,7 +139,7 @@ e_folder_map_dir (const char *dirname, const char *type, GSList **dir_list) continue; } - e_folder_map_dir (full_path, full_path, dir_list); + e_folder_map_dir (full_path, type, dir_list); g_free (full_path); } |