[gnome-software] Make the XML parser a little more accepting of unknown data
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software] Make the XML parser a little more accepting of unknown data
- Date: Tue, 3 Sep 2013 19:11:13 +0000 (UTC)
commit 590de9050985364a607647c63af11ac29e13ff89
Author: Richard Hughes <richard hughsie com>
Date: Tue Sep 3 20:10:25 2013 +0100
Make the XML parser a little more accepting of unknown data
src/plugins/gs-plugin-appstream.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/plugins/gs-plugin-appstream.c b/src/plugins/gs-plugin-appstream.c
index 6fc7203..d159294 100644
--- a/src/plugins/gs-plugin-appstream.c
+++ b/src/plugins/gs-plugin-appstream.c
@@ -341,7 +341,6 @@ gs_appstream_end_element_cb (GMarkupParseContext *context,
section_new = gs_appstream_selection_from_text (element_name);
switch (section_new) {
case GS_APPSTREAM_XML_SECTION_APPLICATIONS:
- case GS_APPSTREAM_XML_SECTION_APPCATEGORIES:
case GS_APPSTREAM_XML_SECTION_APPCATEGORY:
/* ignore */
break;
@@ -359,6 +358,7 @@ gs_appstream_end_element_cb (GMarkupParseContext *context,
break;
case GS_APPSTREAM_XML_SECTION_ID:
case GS_APPSTREAM_XML_SECTION_PKGNAME:
+ case GS_APPSTREAM_XML_SECTION_APPCATEGORIES:
case GS_APPSTREAM_XML_SECTION_NAME:
case GS_APPSTREAM_XML_SECTION_ICON:
case GS_APPSTREAM_XML_SECTION_SUMMARY:
@@ -368,6 +368,7 @@ gs_appstream_end_element_cb (GMarkupParseContext *context,
break;
default:
/* ignore unknown entries */
+ plugin->priv->section = GS_APPSTREAM_XML_SECTION_APPLICATION;
break;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]