From 7479fdeb122bd627d364c18068f3fa8adb9b3990 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Fri, 3 Oct 2008 22:19:40 +0000 Subject: [PATCH] OPENZAP-24 audio problem on alaw wanpipe git-svn-id: http://svn.openzap.org/svn/openzap/trunk@581 a93c3328-9c30-0410-af19-c9cd2b2d52af --- .../src/ozmod/ozmod_wanpipe/ozmod_wanpipe.c | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/libs/openzap/src/ozmod/ozmod_wanpipe/ozmod_wanpipe.c b/libs/openzap/src/ozmod/ozmod_wanpipe/ozmod_wanpipe.c index 933373f47d..acf9ab28c0 100644 --- a/libs/openzap/src/ozmod/ozmod_wanpipe/ozmod_wanpipe.c +++ b/libs/openzap/src/ozmod/ozmod_wanpipe/ozmod_wanpipe.c @@ -524,19 +524,10 @@ static ZIO_OPEN_FUNCTION(wanpipe_open) if (zchan->type == ZAP_CHAN_TYPE_DQ921 || zchan->type == ZAP_CHAN_TYPE_DQ931) { zchan->native_codec = zchan->effective_codec = ZAP_CODEC_NONE; } else { - tdm_api.wp_tdm_cmd.cmd = SIOC_WP_TDM_SET_CODEC; - - if (zchan->native_codec == ZAP_CODEC_ULAW) { - tdm_api.wp_tdm_cmd.tdm_codec = 0; - } else if (zchan->native_codec == ZAP_CODEC_ALAW) { - tdm_api.wp_tdm_cmd.tdm_codec = 1; - } else { - tdm_api.wp_tdm_cmd.tdm_codec = 2; - } zchan->effective_codec = zchan->native_codec; - - wp_tdm_cmd_exec(zchan, &tdm_api); - + tdm_api.wp_tdm_cmd.cmd = SIOC_WP_TDM_SET_CODEC; + tdm_api.wp_tdm_cmd.tdm_codec = 0; + wp_tdm_cmd_exec(zchan, &tdm_api); tdm_api.wp_tdm_cmd.cmd = SIOC_WP_TDM_SET_USR_PERIOD; tdm_api.wp_tdm_cmd.usr_period = wp_globals.codec_ms; wp_tdm_cmd_exec(zchan, &tdm_api);