[Asterisk-cvs] asterisk asterisk.c,1.50,1.51 indications.c,1.6,1.7

markster at lists.digium.com markster at lists.digium.com
Wed Jan 28 15:40:44 CST 2004


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

Modified Files:
	asterisk.c indications.c 
Log Message:
Various minor cleanups (bug #931)


Index: asterisk.c
===================================================================
RCS file: /usr/cvsroot/asterisk/asterisk.c,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -d -r1.50 -r1.51
--- asterisk.c	23 Jan 2004 19:12:44 -0000	1.50
+++ asterisk.c	28 Jan 2004 21:32:48 -0000	1.51
@@ -1232,7 +1232,7 @@
 
 int main(int argc, char *argv[])
 {
-	char c;
+	int c;
 	char filename[80] = "";
 	char hostname[256];
 	char tmp[80];
@@ -1269,7 +1269,7 @@
 	}
 	*/
 	/* Check for options */
-	while((c=getopt(argc, argv, "hfdvqprgcinx:C:")) != EOF) {
+	while((c=getopt(argc, argv, "hfdvqprgcinx:C:")) != -1) {
 		switch(c) {
 		case 'd':
 			option_debug++;

Index: indications.c
===================================================================
RCS file: /usr/cvsroot/asterisk/indications.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- indications.c	8 Jan 2004 15:47:16 -0000	1.6
+++ indications.c	28 Jan 2004 21:32:48 -0000	1.7
@@ -235,7 +235,8 @@
 	if (country) {
 		struct tone_zone *z = ast_get_indication_zone(country);
 		if (z) {
-			ast_verbose(VERBOSE_PREFIX_3 "Setting default indication country to '%s'\n",country);
+			if (option_verbose > 2)
+				ast_verbose(VERBOSE_PREFIX_3 "Setting default indication country to '%s'\n",country);
 			current_tonezone = z;
 			return 0;
 		}
@@ -359,7 +360,8 @@
 		tone_zones = zone;
 	ast_mutex_unlock(&tzlock);
 
-	ast_verbose(VERBOSE_PREFIX_3 "Registered indication country '%s'\n",zone->country);
+	if (option_verbose > 2)
+		ast_verbose(VERBOSE_PREFIX_3 "Registered indication country '%s'\n",zone->country);
 	return 0;
 }
 
@@ -390,7 +392,8 @@
 				ast_log(LOG_NOTICE,"Removed default indication country '%s'\n",tz->country);
 				current_tonezone = NULL;
 			}
-			ast_verbose(VERBOSE_PREFIX_3 "Unregistered indication country '%s'\n",tz->country);
+			if (option_verbose > 2)
+				ast_verbose(VERBOSE_PREFIX_3 "Unregistered indication country '%s'\n",tz->country);
 			free_zone(tz);
 			tz = tmp;
 			res = 0;




More information about the svn-commits mailing list