Fixed a hideous bu in xmlGetProp, reported by Rune.Djurhuus@fast.no, Daniel.
diff --git a/tree.c b/tree.c
index 7616f1b..db2b5d2 100644
--- a/tree.c
+++ b/tree.c
@@ -3398,7 +3398,8 @@
 	    attrDecl = xmlGetDtdAttrDesc(doc->intSubset, node->name, name);
 	    if ((attrDecl == NULL) && (doc->extSubset != NULL))
 		attrDecl = xmlGetDtdAttrDesc(doc->extSubset, node->name, name);
-	    return(xmlStrdup(attrDecl->defaultValue));
+	    if (attrDecl != NULL)
+		return(xmlStrdup(attrDecl->defaultValue));
 	}
     }
     return(NULL);