[asterisk-dev] possible bug in chan_vpb

Russell Bryant russell at digium.com
Sat Nov 22 17:15:23 CST 2008


On Nov 22, 2008, at 12:02 AM, <john at spectross.com>  
<john at spectross.com> wrote:
> I was browsing through "chan_vpb.cc" today. I see that no  
> "fds" (file descriptors) are assigned while creation of an  
> "ast_channel" structure in "vpb_new".
>
> What I am not able to understand is: How would the "ast_waitfor*"  
> functions work as the events are captured using the "poll" api.
>

I have never touched that code, but I can say that there is one other  
method for a channel driver to indicate that data is available.   
Channel drivers can queue up media frames onto the channel using  
ast_queue_frame().  This puts the frame into a queue on the  
ast_channel, and also writes data to an alert pipe on the channel that  
is used to wake up poll().  chan_iax2 uses this method quite heavily  
since there is no dedicated socket per channel like there is for a  
call using RTP.

--
Russell Bryant
Senior Software Engineer
Open Source Team Lead
Digium, Inc.







More information about the asterisk-dev mailing list