[asterisk-dev] [asterisk-commits] jpeeler: branch jpeeler/asterisk-sigwork-trunk r193982 - /team/jpeeler/asteri...

Kevin P. Fleming kpfleming at digium.com
Tue May 12 16:28:41 CDT 2009


SVN commits to the Asterisk project wrote:
> Author: jpeeler
> Date: Tue May 12 16:21:54 2009
> New Revision: 193982
> 
> URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=193982
> Log:
> when bufferoverrideinuse enabled, revert them before analog hangup is called
> 
> Modified:
>     team/jpeeler/asterisk-sigwork-trunk/channels/chan_dahdi.c
> 
> Modified: team/jpeeler/asterisk-sigwork-trunk/channels/chan_dahdi.c
> URL: http://svn.asterisk.org/svn-view/asterisk/team/jpeeler/asterisk-sigwork-trunk/channels/chan_dahdi.c?view=diff&rev=193982&r1=193981&r2=193982
> ==============================================================================
> --- team/jpeeler/asterisk-sigwork-trunk/channels/chan_dahdi.c (original)
> +++ team/jpeeler/asterisk-sigwork-trunk/channels/chan_dahdi.c Tue May 12 16:21:54 2009
> @@ -5240,6 +5240,22 @@
>  		restore_gains(p);
>  		p->ignoredtmf = 0;
>  	
> +		if (p->bufferoverrideinuse) {
> +			/* faxbuffers are in use, revert them */
> +			struct dahdi_bufferinfo bi = {
> +				.txbufpolicy = p->buf_policy,
> +				.rxbufpolicy = p->buf_policy,
> +				.bufsize = p->bufsize,
> +				.numbufs = p->buf_no
> +			};
> +			int bpres;
> +
> +			if ((bpres = ioctl(p->subs[SUB_REAL].dfd, DAHDI_SET_BUFINFO, &bi)) < 0) {
> +				ast_log(LOG_WARNING, "Channel '%s' unable to revert faxbuffer policy: %s\n", ast->name, strerror(errno));
> +			}
> +			p->bufferoverrideinuse = 0;	

With recent changes to CHANNEL() in chan_dahdi, the buffer override
might not have been due to FAX, so this message should be more generic.

-- 
Kevin P. Fleming
Digium, Inc. | Director of Software Technologies
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
skype: kpfleming | jabber: kpfleming at digium.com
Check us out at www.digium.com & www.asterisk.org



More information about the asterisk-dev mailing list