[asterisk-commits] branch group/autoconf_and_menuselect r18306 - /team/group/autoconf_and_menuse...

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Fri Apr 7 09:18:19 MST 2006


Author: russell
Date: Fri Apr  7 11:18:17 2006
New Revision: 18306

URL: http://svn.digium.com/view/asterisk?rev=18306&view=rev
Log:
add various missing changes that exist in the trunk

Modified:
    team/group/autoconf_and_menuselect/apps/app_realtime.c
    team/group/autoconf_and_menuselect/apps/app_transfer.c
    team/group/autoconf_and_menuselect/apps/app_url.c

Modified: team/group/autoconf_and_menuselect/apps/app_realtime.c
URL: http://svn.digium.com/view/asterisk/team/group/autoconf_and_menuselect/apps/app_realtime.c?rev=18306&r1=18305&r2=18306&view=diff
==============================================================================
--- team/group/autoconf_and_menuselect/apps/app_realtime.c (original)
+++ team/group/autoconf_and_menuselect/apps/app_realtime.c Fri Apr  7 11:18:17 2006
@@ -147,19 +147,20 @@
 	
 	LOCAL_USER_ADD(u);
 
-	family = ast_strdupa(data);
-	if ((colmatch = strchr(family,'|'))) {
-		crop_data(colmatch);
-		if ((value = strchr(colmatch,'|'))) {
-			crop_data(value);
-			if ((newcol = strchr(value,'|'))) {
-				crop_data(newcol);
-				if ((newval = strchr(newcol,'|'))) 
-					crop_data(newval);
+	if ((family = ast_strdupa(data))) {
+		if ((colmatch = strchr(family,'|'))) {
+			crop_data(colmatch);
+			if ((value = strchr(colmatch,'|'))) {
+				crop_data(value);
+				if ((newcol = strchr(value,'|'))) {
+					crop_data(newcol);
+					if ((newval = strchr(newcol,'|'))) 
+						crop_data(newval);
+				}
 			}
 		}
 	}
-	if (!newval) {
+	if (! (family && value && colmatch && newcol && newval) ) {
 		ast_log(LOG_ERROR,"Invalid input: usage %s\n",UUSAGE);
 		res = -1;
 	} else {
@@ -191,16 +192,17 @@
 	
 	LOCAL_USER_ADD(u);
 
-	family = ast_strdupa(data);
-	if ((colmatch = strchr(family,'|'))) {
-		crop_data(colmatch);
-		if ((value = strchr(colmatch,'|'))) {
-			crop_data(value);
-			if ((prefix = strchr(value,'|')))
-				crop_data(prefix);
+	if ((family = ast_strdupa(data))) {
+		if ((colmatch = strchr(family,'|'))) {
+			crop_data(colmatch);
+			if ((value = strchr(colmatch,'|'))) {
+				crop_data(value);
+				if ((prefix = strchr(value,'|')))
+					crop_data(prefix);
+			}
 		}
 	}
-	if (!value) {
+	if (! (family && value && colmatch) ) {
 		ast_log(LOG_ERROR,"Invalid input: usage %s\n",USAGE);
 		res = -1;
 	} else {

Modified: team/group/autoconf_and_menuselect/apps/app_transfer.c
URL: http://svn.digium.com/view/asterisk/team/group/autoconf_and_menuselect/apps/app_transfer.c?rev=18306&r1=18305&r2=18306&view=diff
==============================================================================
--- team/group/autoconf_and_menuselect/apps/app_transfer.c (original)
+++ team/group/autoconf_and_menuselect/apps/app_transfer.c Fri Apr  7 11:18:17 2006
@@ -86,7 +86,7 @@
 
 	LOCAL_USER_ADD(u);
 
-	if (ast_strlen_zero(data)) {
+	if (ast_strlen_zero((char *)data)) {
 		ast_log(LOG_WARNING, "Transfer requires an argument ([Tech/]destination[|options])\n");
 		LOCAL_USER_REMOVE(u);
 		pbx_builtin_setvar_helper(chan, "TRANSFERSTATUS", "FAILURE");
@@ -97,8 +97,6 @@
 			return -1;
 		}
 	}
-	
-	parse = ast_strdupa(data);
 
 	AST_STANDARD_APP_ARGS(args, parse);
 

Modified: team/group/autoconf_and_menuselect/apps/app_url.c
URL: http://svn.digium.com/view/asterisk/team/group/autoconf_and_menuselect/apps/app_url.c?rev=18306&r1=18305&r2=18306&view=diff
==============================================================================
--- team/group/autoconf_and_menuselect/apps/app_url.c (original)
+++ team/group/autoconf_and_menuselect/apps/app_url.c Fri Apr  7 11:18:17 2006
@@ -97,6 +97,7 @@
 		return -1;
 	}
 
+	stringp=tmp;
 	strsep(&stringp, "|");
 	options = strsep(&stringp, "|");
 	if (options && !strcasecmp(options, "wait"))



More information about the asterisk-commits mailing list