From f869ea9ce274aaefb04963e51462700d9fd74232 Mon Sep 17 00:00:00 2001 From: Hiltjo Posthuma Date: Mon, 9 Mar 2020 19:23:07 +0100 Subject: sfeed_html/sfeed_frames: fix bold markup for lynx The previous style was not bold: some link The following link is now bold: some link --- sfeed_frames.c | 11 +++++------ sfeed_html.c | 12 ++++++------ 2 files changed, 11 insertions(+), 12 deletions(-) diff --git a/sfeed_frames.c b/sfeed_frames.c index f367bec..84116b0 100644 --- a/sfeed_frames.c +++ b/sfeed_frames.c @@ -55,19 +55,18 @@ printfeed(FILE *fpitems, FILE *fpin, struct feed *f) fprintf(fpitems, "%04d-%02d-%02d %02d:%02d ", tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday, tm->tm_hour, tm->tm_min); - if (isnew) - fputs("", fpitems); if (fields[FieldLink][0]) { fputs("", fpitems); - xmlencode(fields[FieldTitle], fpitems); - fputs("", fpitems); - } else { - xmlencode(fields[FieldTitle], fpitems); } + if (isnew) + fputs("", fpitems); + xmlencode(fields[FieldTitle], fpitems); if (isnew) fputs("", fpitems); + if (fields[FieldLink][0]) + fputs("", fpitems); fputs("\n", fpitems); } fputs("\n", fpitems); diff --git a/sfeed_html.c b/sfeed_html.c index 3afd18f..ac75db0 100644 --- a/sfeed_html.c +++ b/sfeed_html.c @@ -55,19 +55,19 @@ printfeed(FILE *fp, struct feed *f) fprintf(stdout, "%04d-%02d-%02d %02d:%02d ", tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday, tm->tm_hour, tm->tm_min); - if (isnew) - fputs("", stdout); + if (fields[FieldLink][0]) { fputs("", stdout); - xmlencode(fields[FieldTitle], stdout); - fputs("", stdout); - } else { - xmlencode(fields[FieldTitle], stdout); } + if (isnew) + fputs("", stdout); + xmlencode(fields[FieldTitle], stdout); if (isnew) fputs("", stdout); + if (fields[FieldLink][0]) + fputs("", stdout); fputs("\n", stdout); } fputs("\n", stdout); -- cgit v1.2.3