Commit e42c5445 authored by Larry Ewing's avatar Larry Ewing Committed by Larry Ewing

copy the data. We can't ref the byte array and we can't free it so we have

2001-10-10  Larry Ewing  <lewing@ximian.com>

	* mail-display.c (save_url): copy the data.  We can't ref the byte
	array and we can't free it so we have to copy it.

svn path=/trunk/; revision=13546
parent 7ce7e097
2001-10-10 Larry Ewing <lewing@ximian.com>
* mail-display.c (save_url): copy the data. We can't ref the byte
array and we can't free it so we have to copy it.
2001-10-10 <NotZed@Ximian.com>
* mail-ops.c (transfer_messages_transfer): IF the source and
......
......@@ -738,8 +738,11 @@ save_url (MailDisplay *md, const char *url)
name = strrchr (url, '/');
name = name ? name : url;
memstream = camel_stream_mem_new_with_byte_array (ba);
/* we have to copy the data here since the ba may be long gone
* by the time the user actually saves the file
*/
memstream = camel_stream_mem_new_with_buffer (ba->data, ba->len);
wrapper = camel_data_wrapper_new ();
camel_data_wrapper_construct_from_stream (wrapper, memstream);
camel_object_unref (CAMEL_OBJECT (memstream));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment