X-Git-Url: http://git.maemo.org/git/?a=blobdiff_plain;f=src%2Fwidgets%2Fmodest-dnd.c;h=6c40d8b93ea98bc401e9c192930472b232e88066;hb=4fda51ad4fd87952deef84366884dff6a7c447fd;hp=291239fb984b0985009d9d4722ba2550be6557b6;hpb=3192c2fb6e673b1921044541f79f16c07d1dbf37;p=modest diff --git a/src/widgets/modest-dnd.c b/src/widgets/modest-dnd.c index 291239f..6c40d8b 100644 --- a/src/widgets/modest-dnd.c +++ b/src/widgets/modest-dnd.c @@ -50,20 +50,18 @@ modest_dnd_selection_data_set_paths (GtkSelectionData *selection_data, if (selection_data->target == tree_path_as_string_list_atom) { GString *list; - gint i; gchar *result; GList *row; row = selected_rows; list = g_string_new (NULL); - for (i = 0; idata)); - g_string_append (list, "\n"); row = g_list_next (row); + if (row != NULL) + g_string_append (list, "\n"); } - /* Do not include the delimiter in the last one */ - g_string_append (list, gtk_tree_path_to_string (row->data)); result = g_strdup (list->str); g_string_free (list, TRUE);