if (debugBuffer != null) buffer.append (debugBuffer);
    public synchronized void close (String cset) throws UnsupportedEncodingException {	// only use default charset if not explicitly set for this response.	if (charset == null)	    charset = cset;	// if charset is not set, use western encoding	if (charset == null)	    charset = "ISO-8859-1";	boolean error = false;	if (response == null) {	    if (buffer != null) {	        try {	            response = buffer.toString ().getBytes (charset);	        } catch (UnsupportedEncodingException uee) {	            error = true;	            response = buffer.toString ().getBytes ();	        }	        buffer = null; // make sure this is done only once, even with more requsts attached	    } else {	        response = new byte[0];	    }	}	notifyAll ();	// if there was a problem with the encoding, let the app know	if (error)	    throw new UnsupportedEncodingException (charset);    }