[evolution-patches] Patch for mailer's #46398
- From: Federico Mena Quintero <federico ximian com>
- To: evolution-patches ximian com
- Subject: [evolution-patches] Patch for mailer's #46398
- Date: Tue, 15 Jul 2003 14:26:35 -0500
Hi,
This patch fixes the crash in #46398. Doing g_strsplit() on the URI
list yields an array like { "uri", "", NULL }; the empty string makes
camel_uri_new() return NULL and the code was barfing because of this.
OK to commit?
Federico
Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution/mail/ChangeLog,v
retrieving revision 1.2773
diff -u -r1.2773 ChangeLog
--- ChangeLog 15 Jul 2003 09:46:43 -0000 1.2773
+++ ChangeLog 15 Jul 2003 19:19:46 -0000
@@ -1,3 +1,11 @@
+2003-07-15 Federico Mena Quintero <federico ximian com>
+
+ * folder-browser.c (message_list_drag_data_received): Handle
+ invalid URIs, or more likely, the last empty element in a URI list
+ --- g_strsplit() will yield { "uri1", "", NULL }. Fixes #46398.
+
+ * component-factory.c (destination_folder_handle_drop): Likewise.
+
2003-07-15 Yuedong Du <yuedong du sun com>
* mail-config.c: (config_write_style), (mail_config_init): remove
Index: component-factory.c
===================================================================
RCS file: /cvs/gnome/evolution/mail/component-factory.c,v
retrieving revision 1.328
diff -u -r1.328 component-factory.c
--- component-factory.c 11 Jun 2003 16:19:34 -0000 1.328
+++ component-factory.c 15 Jul 2003 19:19:46 -0000
@@ -630,6 +630,10 @@
uri = camel_url_new (url, NULL);
g_free (url);
+
+ if (!uri)
+ continue;
+
url = uri->path;
uri->path = NULL;
camel_url_free (uri);
Index: folder-browser.c
===================================================================
RCS file: /cvs/gnome/evolution/mail/folder-browser.c,v
retrieving revision 1.350
diff -u -r1.350 folder-browser.c
--- folder-browser.c 1 Jan 1997 08:15:04 -0000 1.350
+++ folder-browser.c 15 Jul 2003 19:19:47 -0000
@@ -533,6 +533,10 @@
uri = camel_url_new (url, NULL);
g_free (url);
+
+ if (!uri)
+ continue;
+
url = uri->path;
uri->path = NULL;
camel_url_free (uri);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]