If there is no pubdate in an rss or atom feed item, use the current date/time
authorArt Cancro <ajc@uncensored.citadel.org>
Tue, 5 Apr 2011 16:21:56 +0000 (12:21 -0400)
committerWilfried Goesgens <dothebart@citadel.org>
Sun, 4 Sep 2011 17:40:36 +0000 (17:40 +0000)
citadel/modules/rssclient/serv_rssclient.c

index 67c325a476b0f267333dd54d50ae47ae561ac9f1..0a3d5792c0b145fd6b870a9e2e4bb4b37bae5d9e 100644 (file)
@@ -342,6 +342,10 @@ void rss_save_item(rss_item *ri, rss_aggregator *Cfg)
                                StrBufRFC2047encode(&Encoded, ri->author_or_creator);
                                msg->cm_fields['A'] = SmashStrBuf(&Encoded);
                                msg->cm_fields['P'] = strdup("rss@localhost");
+
+                       }
+                       if (ri->pubdate <= 0) {
+                               ri->pubdate = time(NULL);
                        }
                }
        }