aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobert Bragg <robert@linux.intel.com>2010-11-24 18:11:13 +0000
committerRobert Bragg <robert@linux.intel.com>2010-12-09 22:46:48 +0000
commitbf22db7f5da05e074c2531bf7e75d74ea246d46d (patch)
treeed9646cd9eb446ceff916c5499905f8c180f96c4
parent8e2d625c63b42cba5016e503027faf93fb898e91 (diff)
downloadlibmatchboxwm2-bf22db7f5da05e074c2531bf7e75d74ea246d46d.tar.gz
libmatchboxwm2-bf22db7f5da05e074c2531bf7e75d74ea246d46d.tar.bz2
libmatchboxwm2-bf22db7f5da05e074c2531bf7e75d74ea246d46d.zip
theme: Check status of XML_Parse
We were assuming an error with parsing if XML_Parse returned a non-zero value but actually the API is defined so the opposite is true so we now only report a warning when XML_Parse returns zero.
-rw-r--r--matchbox/mb-wm-theme.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/matchbox/mb-wm-theme.c b/matchbox/mb-wm-theme.c
index f80a669..e610236 100644
--- a/matchbox/mb-wm-theme.c
+++ b/matchbox/mb-wm-theme.c
@@ -464,7 +464,7 @@ mb_wm_theme_new (MBWMManager * wm, const char * theme_path)
while (fgets (buf, sizeof (buf), file))
{
int len = strlen(buf);
- if (XML_Parse(par, buf, len, 0))
+ if (XML_Parse(par, buf, len, 0) == 0)
{
g_warning ("Failed to parse theme %s", path);
goto default_theme;