malloc-fail: Fix erroneous report in xmlNodeGetBaseSafe
diff --git a/tree.c b/tree.c
index 2c13bfc..414979b 100644
--- a/tree.c
+++ b/tree.c
@@ -5406,6 +5406,8 @@
 	if (cur->type == XML_ENTITY_DECL) {
 	    xmlEntityPtr ent = (xmlEntityPtr) cur;
 
+            if (ent->URI == NULL)
+                break;
             xmlFree(ret);
 	    ret = xmlStrdup(ent->URI);
             if (ret == NULL)