[JDEV] Yahoo Transport Problem - FIX

Kevin Limperos klimperos at heuristicdesigns.com
Thu Apr 12 21:16:53 CDT 2001


    After detailed analysis of the Yahoo 0.8-1.4 source, I found the core dump problem can be resolved by altering line 49 of sessions.c inside yahoo_session_end() from:

ghash_remove(s->yti->s, s->user);     

to:

ghash_remove(s->yti->s, jid_full(s->user));


    Without the call to jid_full(...), ghash_remove() fails to remove the closed session from the hash table. My guess is that memory inside the session structure is released, so when the user logsback in and the ghash_get() finds the old session, it starts accessing garbage-collected data and suffers an untimely termination.
    One suggestion is to alter ghash_remove() and xhash_zap() to return meaningful values - and then check said return values in the client code.

-Kevin

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.jabber.org/pipermail/jdev/attachments/20010412/e1386298/attachment-0002.htm>


More information about the JDev mailing list