From fec196ee907f87e880e07bdd4f78d09fae4b49a8 Mon Sep 17 00:00:00 2001 From: 5 Date: Mon, 15 Oct 2001 17:49:52 +0000 Subject: If we have no node content, dont append any value or try to decode it. 2001-10-15 * filter-input.c (xml_decode): If we have no node content, dont append any value or try to decode it. Gets rid of a bunch of annoying warnings. svn path=/trunk/; revision=13677 --- filter/ChangeLog | 6 ++++++ filter/filter-input.c | 9 +++++---- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/filter/ChangeLog b/filter/ChangeLog index 2f6a38e415..9dbdd81358 100644 --- a/filter/ChangeLog +++ b/filter/ChangeLog @@ -1,3 +1,9 @@ +2001-10-15 + + * filter-input.c (xml_decode): If we have no node content, dont + append any value or try to decode it. Gets rid of a bunch of + annoying warnings. + 2001-10-04 Jeffrey Stedfast * vfolder-rule.c (validate): And again here. diff --git a/filter/filter-input.c b/filter/filter-input.c index dc35f2bec3..aa22771bf2 100644 --- a/filter/filter-input.c +++ b/filter/filter-input.c @@ -273,11 +273,12 @@ xml_decode (FilterElement *fe, xmlNodePtr node) if (!strcmp (n->name, type)) { gchar *decstr; str = xmlNodeGetContent (n); - decstr = e_utf8_xml1_decode (str); - if (str) + if (str) { + decstr = e_utf8_xml1_decode (str); xmlFree (str); - d(printf (" '%s'\n", decstr)); - fi->values = g_list_append (fi->values, decstr); + d(printf (" '%s'\n", decstr)); + fi->values = g_list_append (fi->values, decstr); + } } else { g_warning ("Unknown node type '%s' encountered decoding a %s\n", n->name, type); } -- cgit v1.2.3