aboutsummaryrefslogtreecommitdiffstats
path: root/e-util/e-plugin.c
diff options
context:
space:
mode:
authorNot Zed <NotZed@Ximian.com>2004-10-08 10:51:00 +0800
committerMichael Zucci <zucchi@src.gnome.org>2004-10-08 10:51:00 +0800
commitd61821dda2ab26c13ddeb3f86ebceb1f82cc28bd (patch)
treea6c4f9d7f89e1a4d539b44383df687db0b3303d8 /e-util/e-plugin.c
parent85dc511b3a505bd3b1b003afe7998026d79c5ebf (diff)
downloadgsoc2013-evolution-d61821dda2ab26c13ddeb3f86ebceb1f82cc28bd.tar
gsoc2013-evolution-d61821dda2ab26c13ddeb3f86ebceb1f82cc28bd.tar.gz
gsoc2013-evolution-d61821dda2ab26c13ddeb3f86ebceb1f82cc28bd.tar.bz2
gsoc2013-evolution-d61821dda2ab26c13ddeb3f86ebceb1f82cc28bd.tar.lz
gsoc2013-evolution-d61821dda2ab26c13ddeb3f86ebceb1f82cc28bd.tar.xz
gsoc2013-evolution-d61821dda2ab26c13ddeb3f86ebceb1f82cc28bd.tar.zst
gsoc2013-evolution-d61821dda2ab26c13ddeb3f86ebceb1f82cc28bd.zip
handle wrong root element properly. From David Trowbridge
2004-10-08 Not Zed <NotZed@Ximian.com> * e-plugin.c (ep_load): handle wrong root element properly. From David Trowbridge <David.Trowbridge@Colorado.edu> svn path=/trunk/; revision=27503
Diffstat (limited to 'e-util/e-plugin.c')
-rw-r--r--e-util/e-plugin.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/e-util/e-plugin.c b/e-util/e-plugin.c
index 08fc304699..0524fcc81f 100644
--- a/e-util/e-plugin.c
+++ b/e-util/e-plugin.c
@@ -219,8 +219,11 @@ ep_load(const char *filename)
}
root = xmlDocGetRootElement(doc);
- if (strcmp(root->name, "e-plugin-list") != 0)
- goto fail;
+ if (strcmp(root->name, "e-plugin-list") != 0) {
+ g_warning("No <e-plugin-list> root element: %s", filename);
+ xmlFreedoc(doc);
+ return -1;
+ }
pdoc = g_malloc0(sizeof(*pdoc));
pdoc->doc = doc;