abdera-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmsn...@apache.org
Subject svn commit: r420960 - /incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java
Date Tue, 11 Jul 2006 19:42:25 GMT
Author: jmsnell
Date: Tue Jul 11 12:42:24 2006
New Revision: 420960

URL: http://svn.apache.org/viewvc?rev=420960&view=rev
Log:
Fixing a whoopsie. I originally did not account properly for null namespaces on the element

Modified:
    incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java

Modified: incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java?rev=420960&r1=420959&r2=420960&view=diff
==============================================================================
--- incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java
(original)
+++ incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java
Tue Jul 11 12:42:24 2006
@@ -474,7 +474,9 @@
     List<QName> list = new ArrayList<QName>();
     for (Iterator i = getAllAttributes(); i.hasNext();) {
       OMAttribute attr = (OMAttribute) i.next();
-      String namespace = attr.getNamespace().getName();
+      String namespace = 
+        (attr.getNamespace() != null) ? 
+          attr.getNamespace().getName() : "";
       if (!namespace.equals(getNamespace().getName()) &&
           !namespace.equals(""))
         list.add(attr.getQName());



Mime
View raw message