[asterisk-commits] rmudgett: branch group/CCSS r244048 - /team/group/CCSS/channels/chan_dahdi.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Fri Jan 29 13:42:21 CST 2010
Author: rmudgett
Date: Fri Jan 29 13:42:17 2010
New Revision: 244048
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=244048
Log:
Remove code that does not apply to trunk level code.
This code could never get run by sig_analog or sig_pri channels. However,
it could get run for SS7 and MFC/R2 channels with the code either doing
nothing or requesting generic call completion.
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=244048&r1=244047&r2=244048
==============================================================================
--- team/group/CCSS/channels/chan_dahdi.c (original)
+++ team/group/CCSS/channels/chan_dahdi.c Fri Jan 29 13:42:17 2010
@@ -660,7 +660,6 @@
unsigned int needunhold:1;
unsigned int linear:1;
unsigned int inthreeway:1;
- unsigned int ccframesent:1;
struct dahdi_confinfo curconf;
};
@@ -8047,34 +8046,6 @@
return f;
}
-static const char *dahdi_cc_is_possible(struct ast_channel *chan, const char * const device_name)
-{
- struct ast_cc_config_params *cc_params;
- const char *monitor_type;
-
- monitor_type = NULL;
- cc_params = ast_channel_get_cc_config_params(chan);
- if (cc_params) {
- switch (ast_get_cc_monitor_policy(cc_params)) {
- case AST_CC_MONITOR_NEVER:
- break;
- case AST_CC_MONITOR_NATIVE:
- case AST_CC_MONITOR_GENERIC:
- case AST_CC_MONITOR_ALWAYS:
- monitor_type = AST_CC_GENERIC_MONITOR_TYPE;
- break;
- }
- }
-
- if (monitor_type
- && ast_cc_monitor_count(device_name, monitor_type)
- < ast_get_cc_max_monitors(cc_params)) {
- return monitor_type;
- }
-
- return NULL;
-}
-
static struct ast_frame *dahdi_read(struct ast_channel *ast)
{
struct dahdi_pvt *p = ast->tech_pvt;
@@ -8149,28 +8120,6 @@
#endif
if (p->subs[idx].needringing) {
- if (!p->subs[idx].ccframesent) {
- char device_name[256];
- const char *monitor_type;
-
- ast_channel_get_device_name(p->owner, device_name, sizeof(device_name));
- monitor_type = dahdi_cc_is_possible(p->owner, device_name);
- if (monitor_type
- && !ast_cc_build_frame(p->owner, p->cc_params, monitor_type, device_name, p->dialstring, AST_CC_CCNR, &p->subs[idx].f)) {
- p->subs[idx].ccframesent = 1;
- 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.
- *
- * Even if we didn't really send a CC frame, we need to set this
- * true so that we don't repeatedly attempt to send them and never
- * send a ringing frame.
- */
- p->subs[idx].ccframesent = 1;
- }
/* 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