[JDEV] Dialup and laptop users, lost packets, and faulty presence info

Nathan Sharp spamnps+jabber at phoenix-int.com
Thu May 16 22:00:25 CDT 2002


Robert,

Great to hear that 1.5 should be easy (1.4 was pretty easy).  I do have 
some bad news from preliminary testing, though.  Exodus's receive thread 
crashes because of this.  The culprit seems to be XMLStream.pas, the 
function TParseThread.getFullTag has the following code:

    /// find the first tag
/    p := Pos(*'<'*, sbuff);
    *if* p <= 0 *then* *raise* EXMLStream.Create(*''*);

There is no code that I can find which catches this exception, hence the 
thread dying (Exodus stops receiving anything after a heartbeat).  This 
code needs to be modified to just return '' if the input string is 
blank.  I experimented a little with having the server send "<iq/>" for 
a heartbeat instead of " \n", which works great although is technically 
a wrong thing to do.  I don't have delphi so either I'm going to need to 
get someone to compile a fixed version of Exodus 0.6.0.0, or have an 
option for the server's heartbeat function to send something other than 
whitespace.  Hopefully other clients won't exhibit this behavior (so far 
psi and gaim seem o.k.).

Anyhow, not to get ahead of myself, I haven't proven yet that this fixes 
the original problem.  Once I do I'll certainly post here what I have.

Thanks again!
  Nathan

Robert Norris wrote:

>1.5 is a complete rewrite. The code is quite clean and it should be a
>trivial matter to add this. Write a small function that walks c2s->conns
>(and possibly c2s->pending), and calls _write_actual for each one. Hook
>this into the main loop (jadc2s.c:246). MIO will take care of catching
>any error condition and running the appropriate callbacks to clean up.
>
>Hmm, maybe I'll write it myself :P
>  
>






More information about the JDev mailing list