[asterisk-commits] branch 1.2 r19812 - /branches/1.2/apps/app_page.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Thu Apr 13 10:40:22 MST 2006


Author: kpfleming
Date: Thu Apr 13 12:40:21 2006
New Revision: 19812

URL: http://svn.digium.com/view/asterisk?rev=19812&view=rev
Log:
oops... let's not set a variable and then immediately overwrite it while assuming its old value will magically return

Modified:
    branches/1.2/apps/app_page.c

Modified: branches/1.2/apps/app_page.c
URL: http://svn.digium.com/view/asterisk/branches/1.2/apps/app_page.c?rev=19812&r1=19811&r2=19812&view=diff
==============================================================================
--- branches/1.2/apps/app_page.c (original)
+++ branches/1.2/apps/app_page.c Thu Apr 13 12:40:21 2006
@@ -171,15 +171,15 @@
 		return -1;
 	}
 
+	ast_copy_string(originator, chan->name, sizeof(originator));
+	if ((tmp = strchr(originator, '-')))
+		*tmp = '\0';
+
 	tmp = strsep(&options, "|");
 	if (options)
 		ast_app_parse_options(page_opts, &flags, NULL, options);
 
 	snprintf(meetmeopts, sizeof(meetmeopts), "%ud|%sqxdw", confid, ast_test_flag(&flags, PAGE_DUPLEX) ? "" : "m");
-
-	ast_copy_string(originator, chan->name, sizeof(originator));
-	if ((tmp = strchr(originator, '-')))
-		*tmp = '\0';
 
 	while ((tech = strsep(&tmp, "&"))) {
 		/* don't call the originating device */



More information about the asterisk-commits mailing list