[asterisk-commits] trunk r31049 - /trunk/apps/app_dial.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Wed May 31 09:11:56 MST 2006


Author: kpfleming
Date: Wed May 31 11:11:55 2006
New Revision: 31049

URL: http://svn.digium.com/view/asterisk?rev=31049&view=rev
Log:
cleanups for commit from issue #5657... set a cause code for a rejected forward request, and actually set tmp->chan to NULL when we reject the forward request

Modified:
    trunk/apps/app_dial.c

Modified: trunk/apps/app_dial.c
URL: http://svn.digium.com/view/asterisk/trunk/apps/app_dial.c?rev=31049&r1=31048&r2=31049&view=diff
==============================================================================
--- trunk/apps/app_dial.c (original)
+++ trunk/apps/app_dial.c Wed May 31 11:11:55 2006
@@ -488,6 +488,7 @@
 						if (option_verbose > 2)
 							ast_verbose(VERBOSE_PREFIX_3 "Forwarding %s to '%s/%s' prevented.\n", in->name, tech, stuff);
 						c = o->chan = NULL;
+						cause = AST_CAUSE_BUSY;
 					} else {
 						/* Setup parameters */
 						c = o->chan = ast_request(tech, in->nativeformats, stuff, &cause);
@@ -1083,6 +1084,8 @@
 				ast_hangup(tmp->chan);
 				/* If we have been told to ignore forwards, just set this channel to null and continue processing extensions normally */
 				if (ast_test_flag(&opts, OPT_IGNORE_FORWARDING)) {
+					tmp->chan = NULL;
+					cause = AST_CAUSE_BUSY;
 					if (option_verbose > 2)
 						ast_verbose(VERBOSE_PREFIX_3 "Forwarding %s to '%s/%s' prevented.\n", chan->name, tech, stuff);
 				} else {



More information about the asterisk-commits mailing list