diff options
author | Peter Williams <peterw@ximian.com> | 2002-08-03 02:19:53 +0800 |
---|---|---|
committer | Peter Williams <peterw@src.gnome.org> | 2002-08-03 02:19:53 +0800 |
commit | 784fe19dd5554f138a4f24695060ada980665136 (patch) | |
tree | 006e1f3d3cb60bb68194fb3b6ea5678874942dc6 /camel/providers | |
parent | 2834a021870668d98d8184f05b58457d073fb3b6 (diff) | |
download | gsoc2013-evolution-784fe19dd5554f138a4f24695060ada980665136.tar gsoc2013-evolution-784fe19dd5554f138a4f24695060ada980665136.tar.gz gsoc2013-evolution-784fe19dd5554f138a4f24695060ada980665136.tar.bz2 gsoc2013-evolution-784fe19dd5554f138a4f24695060ada980665136.tar.lz gsoc2013-evolution-784fe19dd5554f138a4f24695060ada980665136.tar.xz gsoc2013-evolution-784fe19dd5554f138a4f24695060ada980665136.tar.zst gsoc2013-evolution-784fe19dd5554f138a4f24695060ada980665136.zip |
If the folder name contains the directory separator, reject it.
2002-08-01 Peter Williams <peterw@ximian.com>
* providers/imap/camel-imap-store.c (create_folder): If the folder
name contains the directory separator, reject it.
svn path=/trunk/; revision=17690
Diffstat (limited to 'camel/providers')
-rw-r--r-- | camel/providers/imap/camel-imap-store.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/camel/providers/imap/camel-imap-store.c b/camel/providers/imap/camel-imap-store.c index daee1cde70..2972c52f8b 100644 --- a/camel/providers/imap/camel-imap-store.c +++ b/camel/providers/imap/camel-imap-store.c @@ -1743,7 +1743,15 @@ create_folder (CamelStore *store, const char *parent_name, return NULL; if (!parent_name) parent_name = ""; - + + if (strchr (folder_name, imap_store->dir_sep)) { + camel_exception_setv (ex, CAMEL_EXCEPTION_FOLDER_INVALID_PATH, + _("The folder name \"%s\" is invalid because " + "it containes the character \"%c\""), + folder_name, imap_store->dir_sep); + return NULL; + } + /* check if the parent allows inferiors */ need_convert = FALSE; |