Bugs item #3547784, was opened at 2012-07-23 22:14 Message generated for change (Tracker Item Submitted) made by mischi You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=116035&aid=3547784&group_id=16035
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: dom4j 2.0 Status: Open Resolution: None Priority: 5 Private: No Submitted By: Michael Pradel (mischi) Assigned to: Nobody/Anonymous (nobody) Summary: NullPointerException from BranchTreeNode.getChildCount() Initial Comment: Calling getChildCount() on a newly created BranchTreeNode raises a NullPointerException. E.g.: LeafTreeNode n = new BranchTreeNode(); n.getChildCount(); // raises NPE This is surprising for two reasons: 1) Calling a getter on a new instance shouldn't raise any exception. 2) Doing the same with LeafTreeNode, the superclass of BranchTreeNode, works fine. I.e. BranchTreeNode is incompatible with its own superclass: LeafTreeNode n = new LeafTreeNode(); n.getChildCount(); // OK Is this inconsistency intended? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=116035&aid=3547784&group_id=16035 ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ dom4j-dev mailing list dom4j-dev@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dom4j-dev