[balsa] Use filename in preference to content_id
- From: Peter Bloomfield <PeterB src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [balsa] Use filename in preference to content_id
- Date: Tue, 29 Dec 2009 18:23:02 +0000 (UTC)
commit 9c8614944b47e0e4756b891c74ec266a70dd9609
Author: Peter Bloomfield <PeterBloomfield bellsouth net>
Date: Tue Dec 29 13:21:58 2009 -0500
Use filename in preference to content_id
libbalsa/body.c | 42 ++----------------------------------------
libbalsa/body.h | 4 ----
2 files changed, 2 insertions(+), 44 deletions(-)
---
diff --git a/libbalsa/body.c b/libbalsa/body.c
index 1ea0568..7bd0753 100644
--- a/libbalsa/body.c
+++ b/libbalsa/body.c
@@ -305,9 +305,9 @@ libbalsa_message_body_save_temporary(LibBalsaMessageBody * body, GError **err)
gint fd = -1;
GMimeStream *tmp_stream;
- filename = libbalsa_message_body_get_content_id(body);
+ filename = body->filename;
if (!filename)
- filename = body->filename;
+ filename = libbalsa_message_body_get_content_id(body);
if (!filename)
fd = g_file_open_tmp("balsa-body-XXXXXX",
@@ -408,36 +408,6 @@ libbalsa_message_body_save_vfs(LibBalsaMessageBody * body,
return libbalsa_message_body_save_stream(body, out_stream, filter_crlf, err);
}
-void
-libbalsa_message_body_save_parts_by_id(LibBalsaMessageBody * body,
- guint * count,
- GError ** err)
-{
- GError *tmp_err;
-
- if (!body)
- return;
-
- tmp_err = NULL;
-
- if (libbalsa_message_body_get_content_id(body)) {
- libbalsa_message_body_save_temporary(body, &tmp_err);
- if (tmp_err) {
- g_propagate_error(err, tmp_err);
- return;
- }
- ++*count;
- }
-
- libbalsa_message_body_save_parts_by_id(body->parts, count, &tmp_err);
- if (tmp_err) {
- g_propagate_error(err, tmp_err);
- return;
- }
-
- libbalsa_message_body_save_parts_by_id(body->next, count, err);
-}
-
static GMimeStream *
libbalsa_message_body_stream_add_filter(GMimeStream * stream,
GMimeFilter * filter)
@@ -854,14 +824,6 @@ libbalsa_message_body_get_by_id(LibBalsaMessageBody * body,
return libbalsa_message_body_get_by_id(body->next, id);
}
-gboolean
-libbalsa_message_body_has_cid_part(LibBalsaMessageBody * body)
-{
- return body && (libbalsa_message_body_get_content_id(body)
- || libbalsa_message_body_has_cid_part(body->parts)
- || libbalsa_message_body_has_cid_part(body->next));
-}
-
#ifdef HAVE_GPGME
LibBalsaMsgProtectState
libbalsa_message_body_protect_state(LibBalsaMessageBody *body)
diff --git a/libbalsa/body.h b/libbalsa/body.h
index 36120a2..99d1cca 100644
--- a/libbalsa/body.h
+++ b/libbalsa/body.h
@@ -124,10 +124,6 @@ gboolean libbalsa_message_body_save_vfs(LibBalsaMessageBody * body,
GError **err);
gboolean libbalsa_message_body_save_temporary(LibBalsaMessageBody * body,
GError **err);
-void libbalsa_message_body_save_parts_by_id(LibBalsaMessageBody * body,
- guint * count,
- GError ** err);
-gboolean libbalsa_message_body_has_cid_part(LibBalsaMessageBody * body);
gchar *libbalsa_message_body_get_parameter(LibBalsaMessageBody * body,
const gchar * param);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]