From: Colin Leroy Date: Wed, 23 Feb 2005 08:07:52 +0000 (+0000) Subject: 2005-02-23 [colin] 1.0.1cvs15.6 X-Git-Tag: rel_1_9_6~23 X-Git-Url: http://git.claws-mail.org/?p=claws.git;a=commitdiff_plain;h=257785e47fa633c5a1177a4cc0efc63782e8cebd 2005-02-23 [colin] 1.0.1cvs15.6 * src/compose.c Fix Mimeinfo leakage (including tmp files) * src/procmsg.c Fix tmp file leakage (spotted by Ivan Rayner) --- diff --git a/ChangeLog-gtk2.claws b/ChangeLog-gtk2.claws index 225479b3f..1f2f64cd0 100644 --- a/ChangeLog-gtk2.claws +++ b/ChangeLog-gtk2.claws @@ -1,3 +1,10 @@ +2005-02-23 [colin] 1.0.1cvs15.6 + + * src/compose.c + Fix Mimeinfo leakage (including tmp files) + * src/procmsg.c + Fix tmp file leakage (spotted by Ivan Rayner) + 2005-02-22 [colin] 1.0.1cvs15.5 * src/expldifdlg.c diff --git a/PATCHSETS b/PATCHSETS index 68f297d03..7a8eb7f80 100644 --- a/PATCHSETS +++ b/PATCHSETS @@ -394,3 +394,4 @@ ( cvs diff -u -r 1.115.2.28 -r 1.115.2.29 src/main.c; ) > 1.0.1cvs15.3.patchset ( cvs diff -u -r 1.382.2.104 -r 1.382.2.105 src/compose.c; cvs diff -u -r 1.204.2.31 -r 1.204.2.32 src/prefs_common.c; cvs diff -u -r 1.395.2.54 -r 1.395.2.55 src/summaryview.c; ) > 1.0.1cvs15.4.patchset ( cvs diff -u -r 1.1.4.7 -r 1.1.4.9 src/expldifdlg.c; ) > 1.0.1cvs15.5.patchset +( cvs diff -u -r 1.382.2.105 -r 1.382.2.106 src/compose.c; cvs diff -u -r 1.150.2.20 -r 1.150.2.21 src/procmsg.c; ) > 1.0.1cvs15.6.patchset diff --git a/configure.ac b/configure.ac index 3f39b0bc8..791d90a9f 100644 --- a/configure.ac +++ b/configure.ac @@ -13,7 +13,7 @@ INTERFACE_AGE=0 BINARY_AGE=0 EXTRA_VERSION=15 EXTRA_RELEASE= -EXTRA_GTK2_VERSION=.5 +EXTRA_GTK2_VERSION=.6 if test \( $EXTRA_VERSION -eq 0 \) -o \( "x$EXTRA_RELEASE" != "x" \); then VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}${EXTRA_RELEASE}${EXTRA_GTK2_VERSION} diff --git a/src/compose.c b/src/compose.c index 6702e3d08..aab311b75 100644 --- a/src/compose.c +++ b/src/compose.c @@ -3390,6 +3390,8 @@ static gint compose_write_to_file(Compose *compose, FILE *fp, gint action) return -1; procmime_write_mimeinfo(mimemsg, fp); + + procmime_mimeinfo_free_all(mimemsg); return 0; } diff --git a/src/procmsg.c b/src/procmsg.c index 01d4e19b4..38030e729 100644 --- a/src/procmsg.c +++ b/src/procmsg.c @@ -1173,7 +1173,6 @@ gint procmsg_send_message_queue(const gchar *file) content = file_read_stream_to_str(fp); rewind(fp); - get_tmpfile_in_dir(get_mime_tmp_dir(), &tmp_enc_file); str_write_to_file(content, tmp_enc_file); g_free(content); } else { @@ -1281,11 +1280,15 @@ gint procmsg_send_message_queue(const gchar *file) procmsg_save_to_outbox(outbox, file, TRUE); } else { procmsg_save_to_outbox(outbox, tmp_enc_file, FALSE); - unlink(tmp_enc_file); - free(tmp_enc_file); } } + if (tmp_enc_file != NULL) { + unlink(tmp_enc_file); + free(tmp_enc_file); + tmp_enc_file = NULL; + } + if (replymessageid != NULL || fwdmessageid != NULL) { gchar **tokens; FolderItem *item;