Response base_response = HttpConnection.getCurrentConnection().getResponse(); if (response.isCommitted() || base_response.getStatus()!=-1)
if (response.isCommitted() || HttpConnection.getCurrentConnection().getRequest().isHandled())
        public void handle(String target, HttpServletRequest request, HttpServletResponse response, int dispatch) throws IOException, ServletException {            Response base_response = HttpConnection.getCurrentConnection().getResponse();            if (response.isCommitted() || base_response.getStatus()!=-1)                return;                        String method = request.getMethod();                        if (!method.equals(HttpMethods.GET) || !request.getRequestURI().equals("/")) {                response.sendError(404);                return;               }            response.setStatus(404);            response.setContentType(MimeTypes.TEXT_HTML);                        ByteArrayISO8859Writer writer = new ByteArrayISO8859Writer(1500);            String uri = request.getRequestURI();            uri = StringUtil.replace(uri, "<", "&lt;");            uri = StringUtil.replace(uri, ">", "&gt;");                        writer.write("<HTML>\n<HEAD>\n<TITLE>Error 404 - Not Found");            writer.write("</TITLE>\n<BODY>\n<H2>Error 404 - Not Found.</H2>\n");            writer.write("No service matched or handled this request.<BR>");            writer.write("Known services are: <ul>");            Set servers = ServerManager.this.servers.keySet();            for (Iterator iter = servers.iterator(); iter.hasNext();) {                String serverUri = (String) iter.next();                Server server = (Server) ServerManager.this.servers.get(serverUri);                Handler[] handlers = server.getChildHandlersByClass(ContextHandler.class);                for (int i = 0; handlers != null && i < handlers.length; i++) {                    if (!(handlers[i] instanceof ContextHandler)) {                        continue;                    }                    ContextHandler context = (ContextHandler) handlers[i];                    if (context.isStarted()) {                        writer.write("<li><a href=\"");                        writer.write(serverUri);                        if (!context.getContextPath().startsWith("/")) {                            writer.write("/");                        }                        writer.write(context.getContextPath());                        if (!context.getContextPath().endsWith("/")) {                            writer.write("/");                        }                        writer.write("?wsdl\">");                        writer.write(serverUri);                        writer.write(context.getContextPath());                        writer.write("</a></li>\n");                    } else {                        writer.write("<li>");                        writer.write(serverUri);                        writer.write(context.getContextPath());                        writer.write(" [Stopped]</li>\n");                    }                }            }                        for (int i=0; i < 10; i++) {                writer.write("\n<!-- Padding for IE                  -->");            }                        writer.write("\n</BODY>\n</HTML>\n");            writer.flush();            response.setContentLength(writer.size());            OutputStream out = response.getOutputStream();            writer.writeTo(out);            out.close();        }