ModestMailOperationCreateMsgCallback callback,
gpointer userdata)
{
- ModestMailOperationPrivate *priv;
CreateMsgInfo *info = NULL;
- priv = MODEST_MAIL_OPERATION_GET_PRIVATE(self);
-
info = g_slice_new0 (CreateMsgInfo);
info->mail_op = g_object_ref (self);
state->total = 0;
g_signal_emit (G_OBJECT (self), signals[PROGRESS_CHANGED_SIGNAL],
0, state, NULL);
+
+ /* FIXME: we're leaking the state here, or? valgrind thinks so */
tny_folder_refresh_async (folder,
on_refresh_folder,
g_return_val_if_fail (msg && TNY_IS_MSG(msg), NULL);
- /* Add attachments */
- if (msg != NULL) {
- parts = TNY_LIST (tny_simple_list_new());
- tny_mime_part_get_parts (TNY_MIME_PART (msg), parts);
- tny_list_foreach (parts, add_if_attachment, &attachments_list);
- }
+ parts = TNY_LIST (tny_simple_list_new());
+ tny_mime_part_get_parts (TNY_MIME_PART (msg), parts);
+ tny_list_foreach (parts, add_if_attachment, &attachments_list);
new_msg = create_reply_forward_mail (msg, header, from, signature, TRUE, reply_type,
attachments_list);
if (!tny_mime_part_is_purged (part)) {
guint64 size;
- *attachments_count ++;
+ (*attachments_count) ++;
size = modest_attachment_view_get_size (MODEST_ATTACHMENT_VIEW (att_view));
if (size == 0) {
/* we do a random estimation of the size of an attachment */