[asterisk-commits] mmichelson: branch group/CCSS r235921 - /team/group/CCSS/channels/chan_dahdi.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon Dec 21 13:21:13 CST 2009
Author: mmichelson
Date: Mon Dec 21 13:21:11 2009
New Revision: 235921
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=235921
Log:
Modify dahdi_read a bit.
The logic needs to operate whether the call_forward string is set or not. It
will work either way. Don't set needringing to 0 if we haven't sent back a
ringing frame. Add XXX note to be sure to implement a way of telling if we
already sent a CC frame back so we don't keep sending them forever.
Modified:
team/group/CCSS/channels/chan_dahdi.c
Modified: team/group/CCSS/channels/chan_dahdi.c
URL: http://svnview.digium.com/svn/asterisk/team/group/CCSS/channels/chan_dahdi.c?view=diff&rev=235921&r1=235920&r2=235921
==============================================================================
--- team/group/CCSS/channels/chan_dahdi.c (original)
+++ team/group/CCSS/channels/chan_dahdi.c Mon Dec 21 13:21:11 2009
@@ -8048,23 +8048,23 @@
#endif
if (p->subs[idx].needringing) {
- if (p->call_forward) {
- char device_name[256];
- ast_channel_get_device_name(p->owner, device_name, sizeof(device_name));
- if (dahdi_cc_is_possible(p->owner, device_name)) {
- /* XXX I unfortunately cannot test this at the moment because analog
- * call forwarding is broken in trunk.
- */
- if (!ast_cc_build_frame(p->owner, p->cc_params, device_name, p->dialstring, AST_CC_CCNR, &p->subs[idx].f)) {
- p->subs[idx].needringing = 0;
- ast_mutex_unlock(&p->lock);
- return &p->subs[idx].f;
- }
- }
- /* If CC isn't possible or if we can't build the CC frame properly,
- * then we drop into the typical behavior instead
+ /* XXX Note to Mark. Re-examine when you get back to the
+ * office
+ */
+ char device_name[256];
+ ast_channel_get_device_name(p->owner, device_name, sizeof(device_name));
+ if (dahdi_cc_is_possible(p->owner, device_name)) {
+ /* XXX I'm going to need an indication that I've sent a CC frame so I don't
+ * just keep sending them forever
*/
- }
+ if (!ast_cc_build_frame(p->owner, p->cc_params, device_name, p->dialstring, AST_CC_CCNR, &p->subs[idx].f)) {
+ p->subs[idx].needringing = 0;
+ return &p->subs[idx].f;
+ }
+ }
+ /* If CC isn't possible or if we can't build the CC frame properly,
+ * then we drop into the typical behavior instead
+ */
/* Send ringing frame if requested */
p->subs[idx].needringing = 0;
p->subs[idx].f.frametype = AST_FRAME_CONTROL;
More information about the asterisk-commits
mailing list