Return-Path: Delivered-To: apmail-cocoon-dev-archive@www.apache.org Received: (qmail 37066 invoked from network); 29 Oct 2003 16:01:41 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 29 Oct 2003 16:01:41 -0000 Received: (qmail 36075 invoked by uid 500); 29 Oct 2003 16:01:30 -0000 Delivered-To: apmail-cocoon-dev-archive@cocoon.apache.org Received: (qmail 36053 invoked by uid 500); 29 Oct 2003 16:01:30 -0000 Mailing-List: contact dev-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: dev@cocoon.apache.org Delivered-To: mailing list dev@cocoon.apache.org Received: (qmail 36040 invoked from network); 29 Oct 2003 16:01:30 -0000 Received: from unknown (HELO exchange.sun.com) (192.18.33.10) by daedalus.apache.org with SMTP; 29 Oct 2003 16:01:30 -0000 Received: (qmail 25106 invoked by uid 50); 29 Oct 2003 16:04:41 -0000 Date: 29 Oct 2003 16:04:41 -0000 Message-ID: <20031029160441.25105.qmail@nagoya.betaversion.org> From: bugzilla@apache.org To: dev@cocoon.apache.org Cc: Subject: DO NOT REPLY [Bug 23648] - HTMLGenerator produces NullPointerException on HML-docs with XML-Declaration X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT . ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=23648 HTMLGenerator produces NullPointerException on HML-docs with XML-Declaration email@alfred-fuchs.de changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED ------- Additional Comments From email@alfred-fuchs.de 2003-10-29 16:04 ------- sorry for answering so late: I was on holidays. I tested it and it works fine, but to avoide code duplication I would prevere: DOMStreamer domStreamer = new DOMStreamer(this.contentHandler,this.lexicalHandler); contentHandler.startDocument(); if(xpath != null) { NodeList nl = processor.selectNodeList(doc, xpath); int length = nl.getLength(); for(int i=0;i to the old version: if(xpath != null) { DOMStreamer domStreamer = new DOMStreamer(this.contentHandler,this.lexicalHandler); contentHandler.startDocument(); NodeList nl = processor.selectNodeList(doc, xpath); int length = nl.getLength(); for(int i=0;i