[asterisk-commits] mmichelson: branch group/CCSS r215935 - /team/group/CCSS/main/ccss.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Thu Sep 3 10:04:04 CDT 2009
Author: mmichelson
Date: Thu Sep 3 10:04:01 2009
New Revision: 215935
URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=215935
Log:
Fill in the ao2_callback that the CallCompletionCancel app uses.
Modified:
team/group/CCSS/main/ccss.c
Modified: team/group/CCSS/main/ccss.c
URL: http://svn.asterisk.org/svn-view/asterisk/team/group/CCSS/main/ccss.c?view=diff&rev=215935&r1=215934&r2=215935
==============================================================================
--- team/group/CCSS/main/ccss.c (original)
+++ team/group/CCSS/main/ccss.c Thu Sep 3 10:04:01 2009
@@ -549,6 +549,17 @@
* This is why we pass CMP_STOP in addition to CMP_MATCH.
*/
if (!strcmp(pending_offer->caller, caller)) {
+ return CMP_MATCH | CMP_STOP;
+ }
+ return 0;
+}
+
+static int match_agent(void *obj, void *arg, int flags)
+{
+ struct cc_core_instance *core_instance1 = obj;
+ const char *name = arg;
+
+ if (!strcmp(core_instance1->agent->interface, name)) {
return CMP_MATCH | CMP_STOP;
}
return 0;
@@ -1135,7 +1146,7 @@
*dash = '\0';
}
- if (!(core_instance = ao2_callback(cc_core_instances, 0, match_caller_core_instance, interface))) {
+ if (!(core_instance = ao2_callback(cc_core_instances, 0, match_agent, interface))) {
ast_log(LOG_WARNING, "Cannot fid CC transaction to cancel for caller %s\n", interface);
return -1;
}
More information about the asterisk-commits
mailing list