[jdev] wrong order of queued packets after s2s connection broken for jabberd1.4.3.
tailor
tailor at v2tech.com
Wed Jul 28 21:58:31 CDT 2004
I found a bug in dialback_out.c
in the function
/* util to flush queue to mio */
void dialback_out_qflush(miod md, dboq q)
{
dboq cur, next;
/*=========================================================*/
dboq another = NULL; // reorder
cur = q;
while(cur != NULL)
{
next = cur->next;
cur->next = another; // another
another = cur;
cur = next;
}
cur = another;
/*=========================================================*/
/* cur = q; */
while(cur != NULL)
{
next = cur->next;
dialback_miod_write(md, cur->x);
cur = next;
}
}
this function will be called when a s2s connection established, but
unfortunately, the packet is in a FILO manner which stands for first in
last out. so i add a piece of code to fix this bug.
If i'm right , i would like to share this with other jabber fans.
tailor
More information about the JDev
mailing list