diff options
author | Jon Trowbridge <trow@ximian.com> | 2001-09-27 07:44:10 +0800 |
---|---|---|
committer | Jon Trowbridge <trow@src.gnome.org> | 2001-09-27 07:44:10 +0800 |
commit | 1eb6dc987a1e46ee36211d0417c152e14986f32a (patch) | |
tree | f092a6957ae16ba8784430f15660c4a346f0be9e /mail | |
parent | 7aa81a66d90518b8bda0f01fd2e9b75dba5f10e2 (diff) | |
download | gsoc2013-evolution-1eb6dc987a1e46ee36211d0417c152e14986f32a.tar.gz gsoc2013-evolution-1eb6dc987a1e46ee36211d0417c152e14986f32a.tar.zst gsoc2013-evolution-1eb6dc987a1e46ee36211d0417c152e14986f32a.zip |
strdup our "This message contains invalid recipients" string, since it
2001-09-26 Jon Trowbridge <trow@ximian.com>
* mail-callbacks.c (composer_get_message): strdup our "This
message contains invalid recipients" string, since it gets freed
later. And then don't leak the message string. (Bug #10877)
svn path=/trunk/; revision=13175
Diffstat (limited to 'mail')
-rw-r--r-- | mail/ChangeLog | 4 | ||||
-rw-r--r-- | mail/mail-callbacks.c | 3 |
2 files changed, 6 insertions, 1 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog index 780e1c5a81..6c2ad2b6a5 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,5 +1,9 @@ 2001-09-26 Jon Trowbridge <trow@ximian.com> + * mail-callbacks.c (composer_get_message): strdup our "This + message contains invalid recipients" string, since it gets freed + later. And then don't leak the message string. (Bug #10877) + * mail-format.c (write_address): Use camel_address_format, not camel_address_encode. diff --git a/mail/mail-callbacks.c b/mail/mail-callbacks.c index ee68f9f5c5..449b21f35c 100644 --- a/mail/mail-callbacks.c +++ b/mail/mail-callbacks.c @@ -416,7 +416,7 @@ composer_get_message (EMsgComposer *composer) } if (have_invalid) { - msg = _("This message contains invalid recipients:"); + msg = g_strdup (_("This message contains invalid recipients:")); for (i = 0; recipients[i]; ++i) { if (!e_destination_is_valid (recipients[i])) { new_msg = g_strdup_printf ("%s\n %s", msg, @@ -431,6 +431,7 @@ composer_get_message (EMsgComposer *composer) msg = new_msg; message_box = gnome_message_box_new (msg, GNOME_MESSAGE_BOX_WARNING, GNOME_STOCK_BUTTON_OK, NULL); + g_free (msg); gnome_dialog_run_and_close (GNOME_DIALOG (message_box)); |