Index: mail/ChangeLog
===================================================================
--- mail/ChangeLog	(revision 33821)
+++ mail/ChangeLog	(working copy)
@@ -1,3 +1,12 @@
+2007-07-20  Milan Crha  <mcrha@redhat.com>
+
+	** Fix for bug #303937
+
+	* message-list.c: (ml_drop_async_desc):
+	Added test for non-NULL folder and folder->full_name.
+	* message-list.c: (ml_drop_async_drop), (ml_drop_async_free):
+	Added test for non-NULL folder.
+
 2007-07-17  Sankar P  <psankar@novell.com>
 
 	* em-format-html.c: (efh_format_headers):
Index: mail/message-list.c
===================================================================
--- mail/message-list.c	(revision 33821)
+++ mail/message-list.c	(working copy)
@@ -1862,11 +1862,18 @@
 ml_drop_async_desc (struct _mail_msg *mm, int done)
 {
 	struct _drop_msg *m = (struct _drop_msg *) mm;
+	const gchar *full_name = "";
 
+	if (!m->folder)
+		return g_strdup (full_name);
+
+	if (m->folder->full_name)
+		full_name = m->folder->full_name;
+
 	if (m->move)
-		return g_strdup_printf(_("Moving messages into folder %s"), m->folder->full_name);
+		return g_strdup_printf(_("Moving messages into folder %s"), full_name);
 	else
-		return g_strdup_printf(_("Copying messages into folder %s"), m->folder->full_name);
+		return g_strdup_printf(_("Copying messages into folder %s"), full_name);
 }
 
 static void
@@ -1874,6 +1881,8 @@
 {
 	struct _drop_msg *m = (struct _drop_msg *)mm;
 
+	g_return_if_fail (m->folder != NULL);
+
 	switch (m->info) {
 	case DND_X_UID_LIST:
 		em_utils_selection_get_uidlist(m->selection, m->folder, m->action == GDK_ACTION_MOVE, &mm->ex);
@@ -1911,8 +1920,10 @@
 	struct _drop_msg *m = (struct _drop_msg *)mm;
 	
 	g_object_unref(m->context);
-	camel_object_unref(m->folder);
 
+	if (m->folder)
+		camel_object_unref(m->folder);
+
 	g_free(m->selection->data);
 	g_free(m->selection);
 }
