[Asterisk-cvs] asterisk/apps app_dial.c, 1.117, 1.118 app_osplookup.c, 1.3, 1.4

markster at lists.digium.com markster at lists.digium.com
Wed Jan 5 09:10:13 CST 2005


Update of /usr/cvsroot/asterisk/apps
In directory mongoose.digium.com:/tmp/cvs-serv18430/apps

Modified Files:
	app_dial.c app_osplookup.c 
Log Message:
Merge OSP updates from matt nicholson (with changes)


Index: app_dial.c
===================================================================
RCS file: /usr/cvsroot/asterisk/apps/app_dial.c,v
retrieving revision 1.117
retrieving revision 1.118
diff -u -d -r1.117 -r1.118
--- app_dial.c	4 Jan 2005 04:01:40 -0000	1.117
+++ app_dial.c	5 Jan 2005 15:15:12 -0000	1.118
@@ -1017,7 +1017,7 @@
 		time(&answer_time);
 #ifdef OSP_SUPPORT
 		/* Once call is answered, ditch the OSP Handle */
-		pbx_builtin_setvar_helper(chan, "OSPHANDLE", "");
+		pbx_builtin_setvar_helper(chan, "_OSPHANDLE", "");
 #endif		
 		strncpy(status, "ANSWER", sizeof(status) - 1);
 		/* Ah ha!  Someone answered within the desired timeframe.  Of course after this

Index: app_osplookup.c
===================================================================
RCS file: /usr/cvsroot/asterisk/apps/app_osplookup.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- app_osplookup.c	2 Oct 2004 00:58:31 -0000	1.3
+++ app_osplookup.c	5 Jan 2005 15:15:12 -0000	1.4
@@ -113,12 +113,13 @@
 	if ((res = ast_osp_lookup(chan, provider, temp, chan->cid.cid_num, &result)) > 0) {
 		char tmp[80];
 		snprintf(tmp, sizeof(tmp), "%d", result.handle);
-		pbx_builtin_setvar_helper(chan, "OSPHANDLE", tmp);
-		pbx_builtin_setvar_helper(chan, "OSPTECH", result.tech);
-		pbx_builtin_setvar_helper(chan, "OSPDEST", result.dest);
-		pbx_builtin_setvar_helper(chan, "OSPTOKEN", result.token);
+		pbx_builtin_setvar_helper(chan, "_OSPHANDLE", tmp);
+		pbx_builtin_setvar_helper(chan, "_OSPTECH", result.tech);
+		pbx_builtin_setvar_helper(chan, "_OSPDEST", result.dest);
+		pbx_builtin_setvar_helper(chan, "_OSPTOKEN", result.token);
 		snprintf(tmp, sizeof(tmp), "%d", result.numresults);
-		pbx_builtin_setvar_helper(chan, "OSPRESULTS", tmp);
+		pbx_builtin_setvar_helper(chan, "_OSPRESULTS", tmp);
+
 	} else {
 		if (!res)
 			ast_log(LOG_NOTICE, "OSP Lookup failed for '%s' (provider '%s')\n", temp, provider ? provider : "<default>");
@@ -153,12 +154,12 @@
 		if ((res = ast_osp_next(&result, cause)) > 0) {
 			char tmp[80];
 			snprintf(tmp, sizeof(tmp), "%d", result.handle);
-			pbx_builtin_setvar_helper(chan, "OSPHANDLE", tmp);
-			pbx_builtin_setvar_helper(chan, "OSPTECH", result.tech);
-			pbx_builtin_setvar_helper(chan, "OSPDEST", result.dest);
-			pbx_builtin_setvar_helper(chan, "OSPTOKEN", result.token);
+			pbx_builtin_setvar_helper(chan, "_OSPHANDLE", tmp);
+			pbx_builtin_setvar_helper(chan, "_OSPTECH", result.tech);
+			pbx_builtin_setvar_helper(chan, "_OSPDEST", result.dest);
+			pbx_builtin_setvar_helper(chan, "_OSPTOKEN", result.token);
 			snprintf(tmp, sizeof(tmp), "%d", result.numresults);
-			pbx_builtin_setvar_helper(chan, "OSPRESULTS", tmp);
+			pbx_builtin_setvar_helper(chan, "_OSPRESULTS", tmp);
 		}
 	} else {
 		if (!res) {
@@ -204,7 +205,7 @@
 	result.handle = -1;
 	if (temp && strlen(temp) && (sscanf(temp, "%i", &result.handle) == 1) && (result.handle > -1)) {
 		if (!ast_osp_terminate(result.handle, cause, start, duration)) {
-			pbx_builtin_setvar_helper(chan, "OSPHANDLE", "");
+			pbx_builtin_setvar_helper(chan, "_OSPHANDLE", "");
 			res = 1;
 		}
 	} else {




More information about the svn-commits mailing list