RSSyl: use procheader_date_parse() instead of parseRFC822Date().
[claws.git] / src / plugins / rssyl / libfeed / parser_rss20.c
index 3882750a8760e5445ea063d612fa212e320e7965..25cea33d8d2a9fb762e7af3a5722f715d05967cf 100644 (file)
@@ -22,6 +22,8 @@
 #include <expat.h>
 #include <string.h>
 
+#include <procheader.h>
+
 #include "feed.h"
 #include "feeditem.h"
 #include "feeditemenclosure.h"
@@ -132,7 +134,7 @@ void feed_parser_rss20_end(void *data, const gchar *el)
                        } else if( !strcmp(el, "dc:date") ) {
                                feed->date = parseISO8601Date(text);
                        } else if( !strcmp(el, "pubDate") ) {
-                               feed->date = parseRFC822Date(text);
+                               feed->date = procheader_date_parse(NULL, text, 0);
                        }
 
                        break;
@@ -162,7 +164,7 @@ void feed_parser_rss20_end(void *data, const gchar *el)
                        } else if( !strcmp(el, "dc:date") ) {
                                ctx->curitem->date_modified = parseISO8601Date(text);
                        } else if( !strcmp(el, "pubDate") ) {
-                               ctx->curitem->date_modified = parseRFC822Date(text);
+                               ctx->curitem->date_modified = procheader_date_parse(NULL, text, 0);
                        } else if( !strcmp(el, "dc:creator")) {
                                FILL(ctx->curitem->author)
                        }