X-Git-Url: https://git.wpitchoune.net/gitweb/?a=blobdiff_plain;f=src%2Fmain.c;h=1518bd618e1be511401b273d3cdbc569b4269530;hb=e986bbe93fab2d002797bf40983d91ceb76a133c;hp=fa5e38a028c96ea846b89393c3fa2b6e83d97a17;hpb=09bcceb88ae4a548c573098fc35a884fe0cc96ad;p=prss.git diff --git a/src/main.c b/src/main.c index fa5e38a..1518bd6 100644 --- a/src/main.c +++ b/src/main.c @@ -52,7 +52,8 @@ enum { enum { COL_HEADLINE_TITLE, COL_HEADLINE_ID, - COL_HEADLINE_DATE + COL_HEADLINE_DATE, + COL_HEADLINE_EPOCH_TIME }; static struct option long_options[] = { @@ -140,7 +141,8 @@ void update() cur++; } - ttrs_download_headline_content(feeds); + if (feeds) + ttrs_download_headline_content(feeds); model_state = 0; @@ -342,6 +344,8 @@ int feed_cursor_changed_cbk(GtkTreeView *treeview, gpointer data) h->id, COL_HEADLINE_DATE, date, + COL_HEADLINE_EPOCH_TIME, + h->date, -1); g_free(title); @@ -395,8 +399,9 @@ int headline_cursor_changed_cbk(GtkTreeView *treeview, gpointer data) &iter, COL_HEADLINE_TITLE, headline->title, COL_HEADLINE_DATE, date, + COL_HEADLINE_EPOCH_TIME, headline->date, -1); - g_free(date); + free(date); } else { log_debug("headline not found"); }