fixed a namespace error on attribute reporting bug pointed out by Tobias

* SAX2.c: fixed a namespace error on attribute reporting bug
  pointed out by Tobias Reif
* test/p3p result/p3p result/noent/p3p: this test case was wrong
  using xmlsn instead of xmlns...
Daniel
diff --git a/ChangeLog b/ChangeLog
index 198cb59..d917197 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+Thu Aug 28 23:01:36 CEST 2003 Daniel Veillard <daniel@veillard.com>
+
+	* SAX2.c: fixed a namespace error on attribute reporting bug
+	  pointed out by Tobias Reif
+	* test/p3p result/p3p result/noent/p3p: this test case was wrong
+	  using xmlsn instead of xmlns...
+
 Thu Aug 28 18:25:07 CEST 2003 Igor Zlatkovic <igor@zlatkovic.com>
 
 	* include/libxml/globals.h include/libxml/xmlexports.h: fixed
diff --git a/SAX2.c b/SAX2.c
index a55e6a4..c627b7c 100644
--- a/SAX2.c
+++ b/SAX2.c
@@ -1027,6 +1027,11 @@
     if (ns != NULL) {
 	xmlAttrPtr prop;
 	namespace = xmlSearchNs(ctxt->myDoc, ctxt->node, ns);
+	if (namespace == NULL) {
+	    ctxt->sax->error(ctxt->userData, 
+		 "Namespace prefix %s of attribute %s is not defined\n",
+		             ns, name);
+	}
 
 	prop = ctxt->node->properties;
 	while (prop != NULL) {
diff --git a/result/noent/p3p b/result/noent/p3p
index 5e366b5..195eb42 100644
--- a/result/noent/p3p
+++ b/result/noent/p3p
@@ -1,5 +1,5 @@
 <?xml version="1.0"?>
-<RDF:RDF xmlns:RDF="http://www.w3.org/TR/WD-rdf-syntax#" p3p="http//www.w3.org/TR/1998/WD-P3P10-syntax#proposal.DTD">
+<RDF:RDF xmlns:p3p="http//www.w3.org/TR/1998/WD-P3P10-syntax#proposal.DTD" xmlns:RDF="http://www.w3.org/TR/WD-rdf-syntax#">
 <PROP realm="http://www.CoolCatalog.com/catalogue/" entity="CoolCatalog" agreeID="94df1293a3e519bb" assurance="http://www.TrustUs.org">
   <USES>
   <STATEMENT purp="2,3" recpnt="0" id="0" consq="a site with clothes you'd appreciate.">
diff --git a/result/p3p b/result/p3p
index 5e366b5..195eb42 100644
--- a/result/p3p
+++ b/result/p3p
@@ -1,5 +1,5 @@
 <?xml version="1.0"?>
-<RDF:RDF xmlns:RDF="http://www.w3.org/TR/WD-rdf-syntax#" p3p="http//www.w3.org/TR/1998/WD-P3P10-syntax#proposal.DTD">
+<RDF:RDF xmlns:p3p="http//www.w3.org/TR/1998/WD-P3P10-syntax#proposal.DTD" xmlns:RDF="http://www.w3.org/TR/WD-rdf-syntax#">
 <PROP realm="http://www.CoolCatalog.com/catalogue/" entity="CoolCatalog" agreeID="94df1293a3e519bb" assurance="http://www.TrustUs.org">
   <USES>
   <STATEMENT purp="2,3" recpnt="0" id="0" consq="a site with clothes you'd appreciate.">
diff --git a/test/p3p b/test/p3p
index 1e5fd07..b20cbc7 100644
--- a/test/p3p
+++ b/test/p3p
@@ -1,5 +1,5 @@
 <?xml version="1.0"?>
-<RDF:RDF xmlsn:p3p="http//www.w3.org/TR/1998/WD-P3P10-syntax#proposal.DTD"
+<RDF:RDF xmlns:p3p="http//www.w3.org/TR/1998/WD-P3P10-syntax#proposal.DTD"
          xmlns:RDF="http://www.w3.org/TR/WD-rdf-syntax#">
 <PROP realm="http://www.CoolCatalog.com/catalogue/" 
  entity="CoolCatalog" agreeID="94df1293a3e519bb"