Commit df6a04a9 authored by Jonathan Matthew's avatar Jonathan Matthew

podcast: fix parsed podcast data double free

When we think we're parsing an existing feed, free the parsed data
if it doesn't match up with anything in the feed list.  Otherwise,
create episodes if it's the currently selected feed.  The logic here
was a bit messed up.
parent 5e8d1c1f
......@@ -328,7 +328,9 @@ parse_finished (ParseThreadData *data)
/* if the row is selected, create entries for the channel contents */
if (data->dialog->priv->have_selection && found) {
if (found == FALSE) {
rb_podcast_parse_channel_free (data->channel);
} else if (data->dialog->priv->have_selection) {
GtkTreePath *a;
GtkTreePath *b;
......@@ -340,8 +342,6 @@ parse_finished (ParseThreadData *data)
gtk_tree_path_free (a);
gtk_tree_path_free (b);
} else {
rb_podcast_parse_channel_free (data->channel);
} else {
/* model owns data->channel now */
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