Added tracing stuff to RSSParser.

This commit is contained in:
Fabian Schlenz 2019-12-04 05:58:25 +01:00
parent 23fbddb055
commit 6d452ecbc0

View File

@ -107,6 +107,14 @@ void xmlcb(uint8_t status, char* tagName, uint16_t tagLen, char* data, uint16_t
String tag(tagName); String tag(tagName);
if (status & STATUS_START_TAG) xml_last_tag = tag; if (status & STATUS_START_TAG) xml_last_tag = tag;
if (trace_enabled) {
if (status & STATUS_START_TAG) {
TRACE("Start of tag: %s\n", tagName);
} else if (status & STATUS_END_TAG) {
TRACE("End of tag: %s\n", tagName);
}
}
if (tag.equals("/rss/channel/title") && (status & STATUS_TAG_TEXT)) { if (tag.equals("/rss/channel/title") && (status & STATUS_TAG_TEXT)) {
xml_album_title = data; xml_album_title = data;
} else if (tag.endsWith("/title") && (status & STATUS_TAG_TEXT)) { } else if (tag.endsWith("/title") && (status & STATUS_TAG_TEXT)) {