Re: bpc_send in beepcore C library hangs

"Huston" <[email protected]> Mon, 7 Oct 2002 08:28:03 -0600
Newsgroups gmane.network.beep.beepcore.c.general
Message-ID <020901c26e0d$ef170a50$b728a8c0@zizzing>
This is probably obvious but most likely the reason it is hanging is there
is another thread holding the ios->pn->lock. Check the logs to see if you
can tell what the other threads might be doing.

--Huston

----- Original Message -----
From: Des Smith
To: [email protected]
Cc: [email protected]
Sent: Monday, October 07, 2002 5:55 AM
Subject: [Beepcore-c-users] bpc_send in beepcore C library hangs


When sending a reply from a listener implemented using beepcore-c libraries
bpc_send() is hanging.

I ve tracked it down to the following call

fiostate_unblock_write() in bp_fiostate.c .

The listener is hanging when sending its reply at the following line
highlighted.

bp_fiostate_unblock_write(IOSTATE *ios){

    SEM_WAIT(&ios->pn->lock);
    ios->pn->sessionfds[ios->iostate_index].events |= POLLOUT;
    SEM_POST(&ios->pn->lock);

}

What could cause this to hang in this manner?

Thanks,
Des Smith.




-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf