<br><br><div class="gmail_quote">On Sun, Oct 18, 2009 at 2:46 PM, Tzafrir Cohen <span dir="ltr"><<a href="mailto:tzafrir.cohen@xorcom.com">tzafrir.cohen@xorcom.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Update:<br>
<div class="im"><br>
On Wed, Oct 07, 2009 at 09:12:05PM -0000, Tzafrir Cohen wrote:<br>
><br>
> -----------------------------------------------------------<br>
> This is an automatically generated e-mail. To reply, visit:<br>
> <a href="https://reviewboard.asterisk.org/r/394/" target="_blank">https://reviewboard.asterisk.org/r/394/</a><br>
> -----------------------------------------------------------<br>
><br>
> Review request for Asterisk Developers and Tzafrir Cohen.<br>
><br>
><br>
> Summary<br>
> -------<br>
><br>
> I'm working on the RTP monitoring branch:<br>
><br>
> <a href="http://svn.digium.com/svn/asterisk/team/tzafrir/monitor-rtp/" target="_blank">http://svn.digium.com/svn/asterisk/team/tzafrir/monitor-rtp/</a><br>
> <a href="http://svn.digium.com/svn/asterisk/team/tzafrir/monitor-rtp/doc/monitor-rtp.txt" target="_blank">http://svn.digium.com/svn/asterisk/team/tzafrir/monitor-rtp/doc/monitor-rtp.txt</a><br>
<br>
</div>[snip]<br>
<br>
><br>
> The changes involved:<br>
><br>
<br>
[snip]<br>
<div class="im"><br>
> 2. Allowing ast_writefile to write to a socket<br>
<br>
</div>[snip]<br>
<div class="im"><br>
><br>
> Writing to a socket<br>
> -------------------<br>
> We hook into a mechnism that writes to files and want to convert it to<br>
> sending packets to a remote server. Writing to a file and writing to a<br>
> socket is basically the same (write(2)). Opening is slightly different.<br>
<br>
</div>As of r224438 the interface is cleaner:<br>
<a href="http://svnview.digium.com/svn/asterisk?view=revision&revision=224438" target="_blank">http://svnview.digium.com/svn/asterisk?view=revision&revision=224438</a><br>
<br>
ast_writefile is no longer used. ast_writefd has been exposed as a<br>
separate interface function. The temporary<br>
ast_filestream_xxx_get_filename has been renamed to<br>
ast_filestream_get_fd_state() .<br>
<br>
The filename field of struct ast_filestream is still (ab)used to save<br>
the state information. Is it possible to add another member to that<br>
struct (be that a flag) without breaking ABI?<br>
<br>
Alternatively, another indicator for the fact that a struct<br>
ast_filestream was created with ast_writefd() rather than with<br>
ast_writefile is that the 'flags' field will have a value of 0, which<br>
makes no sense to a file you want to write to (O_RDONLY). But this is<br>
not such a clean approach, I guess.<br>
<div class="im"><br></div></blockquote><div> </div>Just run OrecX on the localhost 127.0.0.1 or another server with a mirrored port.<br><br>Why reinvent the wheel?<br><br>Thanks,<br>Steve T<br></div>