Menu

#46 find_best_seq_to_send algo. needs tuning

open
nobody
core (10)
5
2004-01-15
2004-01-15
Lei Zhang
No

Summary: if a session release request is sent out while
peer is sending us a huge message, session gets stuck.

Details: I added a function bp_close_request() into
wrapper.c which sends <close number='0'> on channel 0.
If this session release request is sent while the peer
is sending us a huge message (fragmented into multiple
frames) on say channel 2, then the session gets stuck.
It appears that the peer cannot finish sending the
remaining frames of the message because we never send a
SEQ to tell the peer that we are ok to receive more
frames. The reason we never send a SEQ on channel 2 is
because find_best_seq_to_send() does this:

if (best->status == 'C' || best->status == 'S' || ...) {
best = test;
}

The channel 2 profile is implemented using
pro_frame_available(), if that matters.

I tried to remove 'best->status == 'C' from above, the
session does not stuck any more. So what's the purpose
of that test???

Discussion


Log in to post a comment.