From: Anthony Minessale Date: Mon, 14 Sep 2009 22:13:43 +0000 (+0000) Subject: fix timer in dtmf generator X-Git-Tag: v1.0.6~38^2~87 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8291ec982eeeeb788d4b15f0d420e144682a5338;p=thirdparty%2Ffreeswitch.git fix timer in dtmf generator git-svn-id: http://svn.openzap.org/svn/openzap/trunk@834 a93c3328-9c30-0410-af19-c9cd2b2d52af --- diff --git a/libs/openzap/src/zap_io.c b/libs/openzap/src/zap_io.c index 0f1c53647d..28e6f12686 100644 --- a/libs/openzap/src/zap_io.c +++ b/libs/openzap/src/zap_io.c @@ -1847,8 +1847,10 @@ static zap_status_t handle_dtmf(zap_channel_t *zchan, zap_size_t datalen) return ZAP_FAIL; } } - - zchan->skip_read_frames = wrote / (1000 / zchan->effective_interval); + + if (x) { + zchan->skip_read_frames = (wrote / (zchan->effective_interval * 8)) + 4; + } } }