diff options
author | Not Zed <NotZed@Ximian.com> | 2004-05-21 11:30:00 +0800 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2004-05-21 11:30:00 +0800 |
commit | cfa1f110a7dabe96457a17f0e42f632f8b111828 (patch) | |
tree | 7b698c3f5ddb7b9ec5769afb8d41cb98767549af /camel/providers/local/camel-maildir-folder.c | |
parent | e660ab7c524cf5e753b3a867f04f3a0ea383517e (diff) | |
download | gsoc2013-evolution-cfa1f110a7dabe96457a17f0e42f632f8b111828.tar gsoc2013-evolution-cfa1f110a7dabe96457a17f0e42f632f8b111828.tar.gz gsoc2013-evolution-cfa1f110a7dabe96457a17f0e42f632f8b111828.tar.bz2 gsoc2013-evolution-cfa1f110a7dabe96457a17f0e42f632f8b111828.tar.lz gsoc2013-evolution-cfa1f110a7dabe96457a17f0e42f632f8b111828.tar.xz gsoc2013-evolution-cfa1f110a7dabe96457a17f0e42f632f8b111828.tar.zst gsoc2013-evolution-cfa1f110a7dabe96457a17f0e42f632f8b111828.zip |
re-arrange the code so exception debug will print the expanded
2004-05-20 Not Zed <NotZed@Ximian.com>
* camel-exception.c (camel_exception_setv): re-arrange the code so
exception debug will print the expanded description.
(camel_exception_set): print exception debug.
* providers/pop3/camel-pop3-folder.c (pop3_get_message): same.
* providers/local/camel-mh-folder.c (mh_get_message) *
providers/local/camel-mbox-folder.c (mbox_get_message): *
providers/local/camel-maildir-folder.c (maildir_get_message):
Don't use INVALID_UID for errors which are more system related.
And sync up all the error messages.
svn path=/trunk/; revision=26028
Diffstat (limited to 'camel/providers/local/camel-maildir-folder.c')
-rw-r--r-- | camel/providers/local/camel-maildir-folder.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/camel/providers/local/camel-maildir-folder.c b/camel/providers/local/camel-maildir-folder.c index eca07efbef..3caa91d771 100644 --- a/camel/providers/local/camel-maildir-folder.c +++ b/camel/providers/local/camel-maildir-folder.c @@ -208,7 +208,9 @@ static CamelMimeMessage *maildir_get_message(CamelFolder * folder, const gchar * /* get the message summary info */ if ((info = camel_folder_summary_uid(folder->summary, uid)) == NULL) { - camel_exception_setv(ex, CAMEL_EXCEPTION_FOLDER_INVALID_UID, _("Cannot get message: %s\n %s"), uid, _("No such message")); + camel_exception_setv(ex, CAMEL_EXCEPTION_FOLDER_INVALID_UID, + _("Cannot get message: %s from folder %s\n %s"), + uid, lf->folder_path, _("No such message")); return NULL; } @@ -220,18 +222,18 @@ static CamelMimeMessage *maildir_get_message(CamelFolder * folder, const gchar * camel_folder_summary_info_free(folder->summary, info); if ((message_stream = camel_stream_fs_new_with_name(name, O_RDONLY, 0)) == NULL) { - camel_exception_setv (ex, CAMEL_EXCEPTION_FOLDER_INVALID_UID, - _("Cannot get message: %s\n %s"), - name, g_strerror (errno)); + camel_exception_setv(ex, CAMEL_EXCEPTION_SYSTEM, + _("Cannot get message: %s from folder %s\n %s"), + uid, lf->folder_path, g_strerror(errno)); g_free(name); return NULL; } message = camel_mime_message_new(); if (camel_data_wrapper_construct_from_stream((CamelDataWrapper *)message, message_stream) == -1) { - camel_exception_setv(ex, (errno==EINTR)?CAMEL_EXCEPTION_USER_CANCEL:CAMEL_EXCEPTION_FOLDER_INVALID_UID, - _("Cannot get message: %s\n %s"), - name, _("Invalid message contents")); + camel_exception_setv(ex, (errno==EINTR)?CAMEL_EXCEPTION_USER_CANCEL:CAMEL_EXCEPTION_SYSTEM, + _("Cannot get message: %s from folder %s\n %s"), + uid, lf->folder_path, _("Invalid message contents")); g_free(name); camel_object_unref((CamelObject *)message_stream); camel_object_unref((CamelObject *)message); |