[asterisk-commits] mmichelson: branch group/CCSS r221034 - in /team/group/CCSS: ./ main/pbx.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Sep 29 17:44:41 CDT 2009


Author: mmichelson
Date: Tue Sep 29 17:44:37 2009
New Revision: 221034

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=221034
Log:
Revert builtin hangup to its trunk version.

I will be making the transition from CC_AVAILABLE to
CC_CALLER_OFFERED a bit differently than originally
planned.


Modified:
    team/group/CCSS/   (props changed)
    team/group/CCSS/main/pbx.c

Propchange: team/group/CCSS/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Tue Sep 29 17:44:37 2009
@@ -1,1 +1,1 @@
-/trunk:1-221007
+/trunk:1-220997

Modified: team/group/CCSS/main/pbx.c
URL: http://svnview.digium.com/svn/asterisk/team/group/CCSS/main/pbx.c?view=diff&rev=221034&r1=221033&r2=221034
==============================================================================
--- team/group/CCSS/main/pbx.c (original)
+++ team/group/CCSS/main/pbx.c Tue Sep 29 17:44:37 2009
@@ -8878,45 +8878,24 @@
  */
 static int pbx_builtin_hangup(struct ast_channel *chan, const char *data)
 {
-	char *parse;
-	AST_DECLARE_APP_ARGS( args,
-		AST_APP_ARG(cause);
-		AST_APP_ARG(cc);
-	);
-
 	ast_set_hangupsource(chan, "dialplan/builtin", 0);
 
-	parse = ast_strdupa(S_OR(data, ""));
-
-	AST_STANDARD_APP_ARGS(args, parse);
-
-	if (!ast_strlen_zero(args.cause)) {
+	if (!ast_strlen_zero(data)) {
 		int cause;
 		char *endptr;
 
-		if ((cause = ast_str2cause(args.cause)) > -1) {
+		if ((cause = ast_str2cause(data)) > -1) {
 			chan->hangupcause = cause;
 			return -1;
 		}
 
-		cause = strtol((const char *) args.cause, &endptr, 10);
-		if (cause != 0 || (args.cause != endptr)) {
+		cause = strtol((const char *) data, &endptr, 10);
+		if (cause != 0 || (data != endptr)) {
 			chan->hangupcause = cause;
 			return -1;
 		}
 
 		ast_log(LOG_WARNING, "Invalid cause given to Hangup(): \"%s\"\n", (char *) data);
-	}
-
-	if (!ast_strlen_zero(args.cc)) {
-		int cc_core_id;
-		char *endptr;
-
-		cc_core_id = strtol((const char *) args.cc, &endptr, 10);
-		if (cc_core_id != 0 || (args.cc != endptr)) {
-			ast_cc_request_state_change(CC_CALLER_OFFERED, cc_core_id,
-					"CC offered to caller");
-		}
 	}
 
 	if (!chan->hangupcause) {




More information about the asterisk-commits mailing list