diff options
author | Ettore Perazzoli <ettore@src.gnome.org> | 2000-09-09 05:17:34 +0800 |
---|---|---|
committer | Ettore Perazzoli <ettore@src.gnome.org> | 2000-09-09 05:17:34 +0800 |
commit | c884f5a0148fa2202108cf53645656db5f0e4636 (patch) | |
tree | 8ed84f007450e5308756a2f2ee29757ff4b6ab15 /shell/e-folder-tree.c | |
parent | db75f8912dff0be20f17946b0131e88ae67ea837 (diff) | |
download | gsoc2013-evolution-c884f5a0148fa2202108cf53645656db5f0e4636.tar.gz gsoc2013-evolution-c884f5a0148fa2202108cf53645656db5f0e4636.tar.zst gsoc2013-evolution-c884f5a0148fa2202108cf53645656db5f0e4636.zip |
Fix `e_folder_tree_get_folder()' so that it returns NULL (instead of
segfaulting) if there is no folder at the specified @path.
svn path=/trunk/; revision=5276
Diffstat (limited to 'shell/e-folder-tree.c')
-rw-r--r-- | shell/e-folder-tree.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/shell/e-folder-tree.c b/shell/e-folder-tree.c index 38a7206051..0c719ca9a4 100644 --- a/shell/e-folder-tree.c +++ b/shell/e-folder-tree.c @@ -306,6 +306,9 @@ e_folder_tree_get_folder (EFolderTree *folder_tree, g_return_val_if_fail (g_path_is_absolute (path), NULL); folder = g_hash_table_lookup (folder_tree->path_to_folder, path); + if (folder == NULL) + return NULL; + return folder->data; } |