if(owner.CONFIG_LOG_ERRORS) owner.writeLog("Failed to send message:\n" + e.toString());
        sendSLPMessage(SLPMessageHeader msg, String addr, int port, int toWait,                       SlpUdpClient comm) throws ServiceLocationException {                                       stupidException = 0;            timer = null;            communicator = comm;            tcpTargets.clear();            if(owner.CONFIG_LOG_MSG) owner.writeLog("Sending Message:\n"+msg.toString());            try {                InetAddress toAddress = InetAddress.getByName(addr);                DatagramPacket p = SLPUtil.createDatagram(msg, toAddress, port);                theRequest = msg;                thePacket = p;                currentTimeout = config_retry;                                // timing..                timer = new Timer();                timer.schedule(new resendTask(), currentTimeout);                timer.schedule(new timeoutTask(), toWait);                                boolean sentOK = false;                while(!sentOK) {                    sentOK = communicator.send(p, msg.getXID(), this);                    if(!sentOK) {                        msg.setXID(msg.nextXID());                        p = SLPUtil.createDatagram(msg, toAddress, port);                        thePacket = p;                    }                }                            }catch(Exception e) {                e.printStackTrace();                weAreDone();                if(owner.CONFIG_LOG_ERRORS) owner.writeLog("Failed to send message:\n" + e.toString());                throw new ServiceLocationException(ServiceLocationException.NETWORK_ERROR);            }            waitForReply();                        // now, we are done with the service discovery.            // did we get any overflows ?            if(!tcpTargets.isEmpty()) {                                SLPTcpClient tcp = new SLPTcpClient(owner);                for(Iterator tcpIter = tcpTargets.iterator(); tcpIter.hasNext(); ) {                    tcpHost host = (tcpHost)tcpIter.next();                    System.out.println("TCP: " + host.address.getHostAddress()+" - " +host.port);                    ((SLPSrvReqMessage)msg).clearResponders();                    msg.clearFlags();                    tcp.sendSlpMessage(msg, host.address.getHostAddress(), host.port, results);                }                             }                        //communicator.close();            communicator = null;            if(stupidException != 0) {                throw new ServiceLocationException(stupidException);            }        }