diff options
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | lib/ephy-node-db.c | 8 |
2 files changed, 12 insertions, 3 deletions
@@ -1,3 +1,10 @@ +2003-03-01 Christian Persch <chpe@cvs.gnome.org> + + * lib/ephy-node-db.c: (ephy_node_db_load_from_file): + + Guard against xml reading error, check for NULL subtree before + trying to parse it. + 2004-03-01 Marco Pesenti Gritti <marco@gnome.org> * embed/downloader-view.c: (downloader_view_add_download), diff --git a/lib/ephy-node-db.c b/lib/ephy-node-db.c index 874b2a30a..21cba5de0 100644 --- a/lib/ephy-node-db.c +++ b/lib/ephy-node-db.c @@ -348,13 +348,15 @@ ephy_node_db_load_from_file (EphyNodeDb *db, && type == XML_READER_TYPE_ELEMENT) { xmlNodePtr subtree; - EphyNode *node; /* grow the subtree and load the node from it */ subtree = xmlTextReaderExpand (reader); - node = ephy_node_new_from_xml (db, subtree); - + if (subtree != NULL) + { + ephy_node_new_from_xml (db, subtree); + } + skip = TRUE; } else if (xmlStrEqual (name, xml_root) |