[asterisk-commits] nadi: branch nadi/trunk-cm r43974 - in /team/nadi/trunk-cm: ./ apps/ channels...

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Fri Sep 29 01:08:07 MST 2006


Author: nadi
Date: Fri Sep 29 03:08:06 2006
New Revision: 43974

URL: http://svn.digium.com/view/asterisk?rev=43974&view=rev
Log:
Merged revisions 43888,43894,43900,43902,43912,43914,43917,43920-43921,43934,43945,43953-43954,43961 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

................
r43888 | pcadach | 2006-09-28 18:01:48 +0200 (Do, 28 Sep 2006) | 9 lines

Merged revisions 43877 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r43877 | pcadach | 2006-09-28 21:56:21 +0600 (?\208?\167?\209?\130?\208?\178, 28 ?\208?\161?\208?\181?\208?\189 2006) | 1 line

Fix compiler warning
........

................
r43894 | file | 2006-09-28 18:19:22 +0200 (Do, 28 Sep 2006) | 18 lines

Merged revisions 43893 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r43893 | file | 2006-09-28 12:17:36 -0400 (Thu, 28 Sep 2006) | 10 lines

Merged revisions 43891 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r43891 | file | 2006-09-28 12:13:55 -0400 (Thu, 28 Sep 2006) | 2 lines

Stop the stream after waitstream returns so that our formats get restored. (issue #7370 reported by kryptolus)

........

................

................
r43900 | kpfleming | 2006-09-28 18:43:40 +0200 (Do, 28 Sep 2006) | 18 lines

Merged revisions 43898 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r43898 | kpfleming | 2006-09-28 11:38:25 -0500 (Thu, 28 Sep 2006) | 10 lines

Merged revisions 43895 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r43895 | kpfleming | 2006-09-28 11:32:44 -0500 (Thu, 28 Sep 2006) | 2 lines

eliminate compiler warning introduced by recent changes

........

................

................
r43902 | bweschke | 2006-09-28 18:54:01 +0200 (Do, 28 Sep 2006) | 19 lines

Merged revisions 43899 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r43899 | bweschke | 2006-09-28 12:41:05 -0400 (Thu, 28 Sep 2006) | 11 lines

Merged revisions 43897 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r43897 | bweschke | 2006-09-28 12:37:15 -0400 (Thu, 28 Sep 2006) | 3 lines

 app_queue is comparing the device names incorrectly while checking their statuses. It's internal list of interfaces includes the dial string, while the argument passed to this function does not have the dial string (/n for a local channel). This causes it to ignore the device state changes because it thinks it belongs to none of its members. (#8040 reported and patch by tim_ringenbach)


........

................

................
r43912 | file | 2006-09-28 19:07:37 +0200 (Do, 28 Sep 2006) | 2 lines

Add jitterbuffer information to sip list settings (issue #7945 reported by sergee)

................
r43914 | file | 2006-09-28 19:15:38 +0200 (Do, 28 Sep 2006) | 10 lines

Merged revisions 43913 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r43913 | file | 2006-09-28 13:14:07 -0400 (Thu, 28 Sep 2006) | 2 lines

Warning be gone!

........

................
r43917 | file | 2006-09-28 19:32:46 +0200 (Do, 28 Sep 2006) | 10 lines

Merged revisions 43915 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r43915 | file | 2006-09-28 13:31:09 -0400 (Thu, 28 Sep 2006) | 2 lines

Make sure the pvt exists before accessing it again as it may have gone away (issue #7562 reported by Seb7 and issue #7939 reported by sorg)

........

................
r43920 | pcadach | 2006-09-28 19:36:33 +0200 (Do, 28 Sep 2006) | 9 lines

Merged revisions 43918 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r43918 | pcadach | 2006-09-28 23:34:19 +0600 (?\208?\167?\209?\130?\208?\178, 28 ?\208?\161?\208?\181?\208?\189 2006) | 1 line

Extend call establishment timeout
........

................
r43921 | kpfleming | 2006-09-28 19:38:07 +0200 (Do, 28 Sep 2006) | 18 lines

Merged revisions 43919 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r43919 | kpfleming | 2006-09-28 12:35:42 -0500 (Thu, 28 Sep 2006) | 10 lines

Merged revisions 43916 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r43916 | kpfleming | 2006-09-28 12:31:57 -0500 (Thu, 28 Sep 2006) | 2 lines

fix buggy (and overly complex) loop used during reload of app_queue for static member list updating

........

................

................
r43934 | file | 2006-09-28 20:09:01 +0200 (Do, 28 Sep 2006) | 10 lines

Merged revisions 43933 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r43933 | file | 2006-09-28 14:05:43 -0400 (Thu, 28 Sep 2006) | 2 lines

Put in missing \ns on the end of ast_logs (issue #7936 reported by wojtekka)

........

................
r43945 | qwell | 2006-09-28 22:13:09 +0200 (Do, 28 Sep 2006) | 12 lines

Merged revisions 43944 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r43944 | qwell | 2006-09-28 13:11:22 -0700 (Thu, 28 Sep 2006) | 4 lines

Fix incorrect argument order for member names, on persisted members.

Issue 8047, patch by jmls.

........

................
r43953 | kpfleming | 2006-09-29 00:43:24 +0200 (Fr, 29 Sep 2006) | 10 lines

Merged revisions 43952 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r43952 | kpfleming | 2006-09-28 17:42:18 -0500 (Thu, 28 Sep 2006) | 2 lines

eliminate compiler warning when DEBUG_CHANNEL_LOCKS is enabled and users of this header file don't also include channel.h

........

................
r43954 | file | 2006-09-29 00:49:55 +0200 (Fr, 29 Sep 2006) | 2 lines

Cache the application pointer so we don't have to needlessly search for it over and over. This should yield a suitable performance increase.

................
r43961 | file | 2006-09-29 03:36:26 +0200 (Fr, 29 Sep 2006) | 2 lines

One must remember to unlock their list... thanks to Qwell for letting me into his box

................

Modified:
    team/nadi/trunk-cm/   (props changed)
    team/nadi/trunk-cm/apps/app_alarmreceiver.c
    team/nadi/trunk-cm/apps/app_festival.c
    team/nadi/trunk-cm/apps/app_followme.c
    team/nadi/trunk-cm/apps/app_meetme.c
    team/nadi/trunk-cm/apps/app_playback.c
    team/nadi/trunk-cm/apps/app_queue.c
    team/nadi/trunk-cm/apps/app_rpt.c
    team/nadi/trunk-cm/channels/chan_iax2.c
    team/nadi/trunk-cm/channels/chan_mgcp.c
    team/nadi/trunk-cm/channels/chan_misdn.c
    team/nadi/trunk-cm/channels/chan_sip.c
    team/nadi/trunk-cm/channels/chan_skinny.c
    team/nadi/trunk-cm/channels/h323/ast_h323.cxx
    team/nadi/trunk-cm/channels/iax2-provision.c
    team/nadi/trunk-cm/funcs/func_timeout.c
    team/nadi/trunk-cm/include/asterisk/lock.h
    team/nadi/trunk-cm/include/asterisk/logger.h
    team/nadi/trunk-cm/main/cli.c
    team/nadi/trunk-cm/main/frame.c
    team/nadi/trunk-cm/main/pbx.c
    team/nadi/trunk-cm/main/udptl.c
    team/nadi/trunk-cm/res/res_monitor.c
    team/nadi/trunk-cm/res/res_musiconhold.c
    team/nadi/trunk-cm/res/res_smdi.c

Propchange: team/nadi/trunk-cm/
------------------------------------------------------------------------------
    automerge = *

Propchange: team/nadi/trunk-cm/
------------------------------------------------------------------------------
    automerge-email = nadi at beronet.com

Propchange: team/nadi/trunk-cm/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/nadi/trunk-cm/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Fri Sep 29 03:08:06 2006
@@ -1,1 +1,1 @@
-/trunk:1-43875
+/trunk:1-43973

Modified: team/nadi/trunk-cm/apps/app_alarmreceiver.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/apps/app_alarmreceiver.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/apps/app_alarmreceiver.c (original)
+++ team/nadi/trunk-cm/apps/app_alarmreceiver.c Fri Sep 29 03:08:06 2006
@@ -136,7 +136,7 @@
 	res = ast_db_put(db_family, key, value);
 	
 	if((res)&&(option_verbose >= 4))
-		ast_verbose(VERBOSE_PREFIX_4 "AlarmReceiver: database_increment write error");
+		ast_verbose(VERBOSE_PREFIX_4 "AlarmReceiver: database_increment write error\n");
 	
 	return;	
 }

Modified: team/nadi/trunk-cm/apps/app_festival.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/apps/app_festival.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/apps/app_festival.c (original)
+++ team/nadi/trunk-cm/apps/app_festival.c Fri Sep 29 03:08:06 2006
@@ -485,7 +485,7 @@
                         * */
                        if ( read_data == -1 )
                        {
-                               ast_log(LOG_WARNING,"Unable to read from cache/festival fd");
+                               ast_log(LOG_WARNING,"Unable to read from cache/festival fd\n");
 			       close(fd);
 			       ast_config_destroy(cfg);
 			       ast_module_user_remove(u);

Modified: team/nadi/trunk-cm/apps/app_followme.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/apps/app_followme.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/apps/app_followme.c (original)
+++ team/nadi/trunk-cm/apps/app_followme.c Fri Sep 29 03:08:06 2006
@@ -951,7 +951,7 @@
 	if (option_debug)
 		ast_log(LOG_DEBUG, "New profile %s.\n", args.followmeid);
 	if (!f) { 
-		ast_log(LOG_WARNING, "Profile requested, %s, not found in the configuration.", args.followmeid);
+		ast_log(LOG_WARNING, "Profile requested, %s, not found in the configuration.\n", args.followmeid);
 		res = -1;
 	} else {
 		/* XXX TODO: Reinsert the db check value to see whether or not follow-me is on or off */

Modified: team/nadi/trunk-cm/apps/app_meetme.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/apps/app_meetme.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/apps/app_meetme.c (original)
+++ team/nadi/trunk-cm/apps/app_meetme.c Fri Sep 29 03:08:06 2006
@@ -1154,6 +1154,7 @@
 		if (conf->users == 2) { 
 			if (!ast_streamfile(chan,"conf-onlyone",chan->language)) {
 				res = ast_waitstream(chan, AST_DIGIT_ANY);
+				ast_stopstream(chan);
 				if (res > 0)
 					keepplaying=0;
 				else if (res == -1)
@@ -1162,6 +1163,7 @@
 		} else { 
 			if (!ast_streamfile(chan, "conf-thereare", chan->language)) {
 				res = ast_waitstream(chan, AST_DIGIT_ANY);
+				ast_stopstream(chan);
 				if (res > 0)
 					keepplaying=0;
 				else if (res == -1)
@@ -1176,6 +1178,7 @@
 			}
 			if (keepplaying && !ast_streamfile(chan, "conf-otherinparty", chan->language)) {
 				res = ast_waitstream(chan, AST_DIGIT_ANY);
+				ast_stopstream(chan);
 				if (res > 0)
 					keepplaying=0;
 				else if (res == -1) 
@@ -2358,8 +2361,10 @@
 								break;
 							} else {
 								/* Pin invalid */
-								if (!ast_streamfile(chan, "conf-invalidpin", chan->language))
+								if (!ast_streamfile(chan, "conf-invalidpin", chan->language)) {
 									res = ast_waitstream(chan, AST_DIGIT_ANY);
+									ast_stopstream(chan);
+								}
 								else {
 									ast_log(LOG_WARNING, "Couldn't play invalid pin msg!\n");
 									break;

Modified: team/nadi/trunk-cm/apps/app_playback.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/apps/app_playback.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/apps/app_playback.c (original)
+++ team/nadi/trunk-cm/apps/app_playback.c Fri Sep 29 03:08:06 2006
@@ -341,7 +341,7 @@
                 return RESULT_SHOWUSAGE;
         mode = argv[2];
 
-	ast_log(LOG_WARNING, "init say.c from %s to %s", old_mode, mode);
+	ast_log(LOG_WARNING, "init say.c from %s to %s\n", old_mode, mode);
 
 	if (!strcmp(mode, old_mode)) {
 		ast_log(LOG_WARNING, "say mode is %s already\n", mode);

Modified: team/nadi/trunk-cm/apps/app_queue.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/apps/app_queue.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/apps/app_queue.c (original)
+++ team/nadi/trunk-cm/apps/app_queue.c Fri Sep 29 03:08:06 2006
@@ -517,7 +517,14 @@
 
 	AST_LIST_LOCK(&interfaces);
 	AST_LIST_TRAVERSE(&interfaces, curint, list) {
-		if (!strcasecmp(curint->interface, sc->dev))
+		char *interface;
+		char *slash_pos;
+		interface = ast_strdupa(curint->interface);
+		if ((slash_pos = strchr(interface, '/')))
+			if ((slash_pos = strchr(slash_pos + 1, '/')))
+				*slash_pos = '\0';
+
+		if (!strcasecmp(interface, sc->dev))
 			break;
 	}
 	AST_LIST_UNLOCK(&interfaces);
@@ -535,7 +542,14 @@
 	AST_LIST_TRAVERSE(&queues, q, list) {
 		ast_mutex_lock(&q->lock);
 		for (cur = q->members; cur; cur = cur->next) {
-			if (strcasecmp(sc->dev, cur->interface))
+			char *interface;
+			char *slash_pos;
+			interface = ast_strdupa(cur->interface);
+			if ((slash_pos = strchr(interface, '/')))
+				if ((slash_pos = strchr(slash_pos + 1, '/')))
+					*slash_pos = '\0';
+
+			if (strcasecmp(sc->dev, interface))
 				continue;
 
 			if (cur->status != sc->state) {
@@ -2932,7 +2946,7 @@
 			if (option_debug)
 				ast_log(LOG_DEBUG, "Reload Members: Queue: %s  Member: %s  Name: %s  Penalty: %d  Paused: %d\n", queue_name, interface, membername, penalty, paused);
 			
-			if (add_to_queue(queue_name, membername, interface, penalty, paused, 0) == RES_OUTOFMEMORY) {
+			if (add_to_queue(queue_name, interface, membername, penalty, paused, 0) == RES_OUTOFMEMORY) {
 				ast_log(LOG_ERROR, "Out of Memory when reloading persistent queue member\n");
 				break;
 			}
@@ -3657,7 +3671,7 @@
 	struct ast_config *cfg;
 	char *cat, *tmp;
 	struct ast_variable *var;
-	struct member *prev, *cur, *newm;
+	struct member *prev, *cur, *newm, *next;
 	int new;
 	const char *general_val = NULL;
 	char parse[80];
@@ -3774,22 +3788,19 @@
 				}
 
 				/* Free remaining members marked as delme */
-				for (prev = NULL, newm = NULL, cur = q->members; cur; prev = cur, cur = cur->next) {
-					if (newm) {
-						free(newm);
-						newm = NULL;
-					}
-
-					if (cur->delme) {
-						if (prev) {
-							prev->next = cur->next;
-							newm = cur;
-						} else {
-							q->members = cur->next;
-							newm = cur;
-						}
-						remove_from_interfaces(cur->interface);
-					}
+				for (prev = NULL, cur = q->members, next = cur ? cur->next : NULL;
+				     cur;
+				     cur = next, next = cur ? cur->next : NULL) {
+					if (!cur->delme)
+						continue;
+
+					if (prev)
+						prev->next = next;
+					else
+						q->members = next;
+
+					remove_from_interfaces(cur->interface);
+					free(cur);
 				}
 
 				if (new) {

Modified: team/nadi/trunk-cm/apps/app_rpt.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/apps/app_rpt.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/apps/app_rpt.c (original)
+++ team/nadi/trunk-cm/apps/app_rpt.c Fri Sep 29 03:08:06 2006
@@ -2618,7 +2618,7 @@
 		rpt_mutex_lock(&myrpt->lock);
 		remque((struct qlem *) tele); /* We don't like stuck transmitters, remove it from the queue */
 		rpt_mutex_unlock(&myrpt->lock);	
-		ast_log(LOG_WARNING, "Could not create telemetry thread: %s",strerror(res));
+		ast_log(LOG_WARNING, "Could not create telemetry thread: %s\n",strerror(res));
 	}
 	return;
 }

Modified: team/nadi/trunk-cm/channels/chan_iax2.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/channels/chan_iax2.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/channels/chan_iax2.c (original)
+++ team/nadi/trunk-cm/channels/chan_iax2.c Fri Sep 29 03:08:06 2006
@@ -1534,6 +1534,8 @@
 		destroy_firmware(cur);
 	}
 	AST_LIST_TRAVERSE_SAFE_END
+
+	AST_LIST_UNLOCK(&firmwares);
 }
 
 static int __do_deliver(void *data)
@@ -5380,7 +5382,7 @@
 	username = strsep(&stringp, "@");
 	hostname = strsep(&stringp, "@");
 	if (!hostname) {
-		ast_log(LOG_WARNING, "Format for registration is user[:secret]@host[:port] at line %d", lineno);
+		ast_log(LOG_WARNING, "Format for registration is user[:secret]@host[:port] at line %d\n", lineno);
 		return -1;
 	}
 	stringp=username;
@@ -7526,7 +7528,7 @@
 	if (duped_fr) {
 		schedule_delivery(duped_fr, updatehistory, 0, &fr->ts);
 	}
-	if (iaxs[fr->callno]->last < fr->ts) {
+	if (iaxs[fr->callno] && iaxs[fr->callno]->last < fr->ts) {
 		iaxs[fr->callno]->last = fr->ts;
 #if 1
 		if (option_debug && iaxdebug)

Modified: team/nadi/trunk-cm/channels/chan_mgcp.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/channels/chan_mgcp.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/channels/chan_mgcp.c (original)
+++ team/nadi/trunk-cm/channels/chan_mgcp.c Fri Sep 29 03:08:06 2006
@@ -2980,7 +2980,7 @@
 				ast_log(LOG_WARNING, "Off hook, but already have owner on %s@%s\n", p->name, p->parent->name);
 			} else {
 				ast_log(LOG_WARNING, "On hook, but already have owner on %s@%s\n", p->name, p->parent->name);
-				ast_log(LOG_WARNING, "If we're onhook why are we here trying to handle a hd or hf?");
+				ast_log(LOG_WARNING, "If we're onhook why are we here trying to handle a hd or hf?\n");
 			}
 			if (ast_bridged_channel(sub->owner))
 				ast_queue_control(sub->owner, AST_CONTROL_UNHOLD);
@@ -3769,7 +3769,7 @@
 								e->sub = sub;
 							} else {
 								/* XXX Should find a way to clean up our memory */
-								ast_log(LOG_WARNING, "Out of memory allocating subchannel");
+								ast_log(LOG_WARNING, "Out of memory allocating subchannel\n");
 								return NULL;
 							}
 	 					}
@@ -3886,7 +3886,7 @@
 							sub->nat = nat;
 						} else {
 							/* XXX Should find a way to clean up our memory */
-							ast_log(LOG_WARNING, "Out of memory allocating subchannel");
+							ast_log(LOG_WARNING, "Out of memory allocating subchannel\n");
 							return NULL;
 						}
 					}

Modified: team/nadi/trunk-cm/channels/chan_misdn.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/channels/chan_misdn.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/channels/chan_misdn.c (original)
+++ team/nadi/trunk-cm/channels/chan_misdn.c Fri Sep 29 03:08:06 2006
@@ -1896,7 +1896,7 @@
 	
 	{
 		struct chan_list *ch=MISDN_ASTERISK_TECH_PVT(ast);
-		if (!ch) { ast_verbose("No chan_list in misdn_call"); return -1;}
+		if (!ch) { ast_verbose("No chan_list in misdn_call\n"); return -1;}
 		
 		newbc->capability=ast->transfercapability;
 		pbx_builtin_setvar_helper(ast,"TRANSFERCAPABILITY",ast_transfercapability2str(newbc->capability));
@@ -2392,7 +2392,7 @@
  	if (!f || (f->frametype != AST_FRAME_DTMF))
  		return frame;
  
- 	ast_log(LOG_DEBUG, "Detected inband DTMF digit: %c", f->subclass);
+ 	ast_log(LOG_DEBUG, "Detected inband DTMF digit: %c\n", f->subclass);
  
  	if (tmp->faxdetect && (f->subclass == 'f')) {
  		/* Fax tone -- Handle and return NULL */

Modified: team/nadi/trunk-cm/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/channels/chan_sip.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/channels/chan_sip.c (original)
+++ team/nadi/trunk-cm/channels/chan_sip.c Fri Sep 29 03:08:06 2006
@@ -3977,7 +3977,7 @@
 				p->t38.state = T38_LOCAL_REINVITE;
 				transmit_reinvite_with_t38_sdp(p);
 				if (option_debug > 1)
-					ast_log(LOG_DEBUG, "T38 state changed to %d on channel %s", p->t38.state, ast->name);
+					ast_log(LOG_DEBUG, "T38 state changed to %d on channel %s\n", p->t38.state, ast->name);
 			}
 		} else if (!ast_test_flag(&p->flags[0], SIP_PENDINGBYE)) {
 			if (option_debug > 2)
@@ -10001,6 +10001,12 @@
 	ast_cli(fd, "  T38 fax pt RTP:         %s\n", ast_test_flag(&global_flags[1], SIP_PAGE2_T38SUPPORT_RTP) ? "Yes" : "No");
 	ast_cli(fd, "  T38 fax pt TCP:         %s\n", ast_test_flag(&global_flags[1], SIP_PAGE2_T38SUPPORT_TCP) ? "Yes" : "No");
 	ast_cli(fd, "  RFC2833 Compensation:   %s\n", ast_test_flag(&global_flags[1], SIP_PAGE2_RFC2833_COMPENSATE) ? "Yes" : "No");
+	ast_cli(fd, "  Jitterbuffer enabled:   %s\n", ast_test_flag(&global_jbconf, AST_JB_ENABLED) ? "Yes" : "No");
+	ast_cli(fd, "  Jitterbuffer forced:    %s\n", ast_test_flag(&global_jbconf, AST_JB_FORCED) ? "Yes" : "No");
+	ast_cli(fd, "  Jitterbuffer max size:  %ld\n", global_jbconf.max_size);
+	ast_cli(fd, "  Jitterbuffer resync:    %ld\n", global_jbconf.resync_threshold);
+	ast_cli(fd, "  Jitterbuffer impl:      %s\n", global_jbconf.impl);
+	ast_cli(fd, "  Jitterbuffer log:       %s\n", ast_test_flag(&global_jbconf, AST_JB_LOG) ? "Yes" : "No");
 	if (!realtimepeers && !realtimeusers)
 		ast_cli(fd, "  SIP realtime:           Disabled\n" );
 	else
@@ -14277,10 +14283,7 @@
 	parse_request(&req);
 	req.method = find_sip_method(req.rlPart1);
 	if (ast_test_flag(&req, SIP_PKT_DEBUG)) {
-		ast_verbose("--- (%d headers %d lines)", req.headers, req.lines);
-		if (req.headers + req.lines == 0) 
-			ast_verbose(" Nat keepalive ");
-		ast_verbose("---\n");
+		ast_verbose("--- (%d headers %d lines)%s ---\n", req.headers, req.lines, (req.headers + req.lines == 0) ? " Nat keepalive" : "");
 	}
 
 	if (req.headers < 2) {

Modified: team/nadi/trunk-cm/channels/chan_skinny.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/channels/chan_skinny.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/channels/chan_skinny.c (original)
+++ team/nadi/trunk-cm/channels/chan_skinny.c Fri Sep 29 03:08:06 2006
@@ -4479,7 +4479,7 @@
 	if (skinnysock < 0) {
 		skinnysock = socket(AF_INET, SOCK_STREAM, 0);
 		if(setsockopt(skinnysock, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)) == -1) {
-			ast_log(LOG_ERROR, "Set Socket Options failed: errno %d, %s", errno, strerror(errno));
+			ast_log(LOG_ERROR, "Set Socket Options failed: errno %d, %s\n", errno, strerror(errno));
 			ast_config_destroy(cfg);
 			return 0;
 		}

Modified: team/nadi/trunk-cm/channels/h323/ast_h323.cxx
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/channels/h323/ast_h323.cxx?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/channels/h323/ast_h323.cxx (original)
+++ team/nadi/trunk-cm/channels/h323/ast_h323.cxx Fri Sep 29 03:08:06 2006
@@ -224,8 +224,11 @@
 MyH323EndPoint::MyH323EndPoint()
 		: H323EndPoint()
 {
-	// Capabilities will be negotiated on per-connection basis
+	/* Capabilities will be negotiated on per-connection basis */
 	capabilities.RemoveAll();
+
+	/* Reset call setup timeout to some more reasonable value than 1 minute */
+	signallingChannelCallTimeout = PTimeInterval(0, 0, 10);	/* 10 minutes */
 }
 
 /** The fullAddress parameter is used directly in the MakeCall method so
@@ -1060,7 +1063,7 @@
 		for (int i = 0; i < protos.GetSize(); ++i)
 		{
 			if ((protos[i].GetTag() == H225_TunnelledProtocol_id::e_tunnelledProtocolObjectID) &&
-					(((const PASN_ObjectId &)protos[i]).AsString() == OID_QSIG)) {
+					(((PASN_ObjectId &)protos[i]).AsString() == OID_QSIG)) {
 				addQSIG = FALSE;
 				break;
 			}

Modified: team/nadi/trunk-cm/channels/iax2-provision.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/channels/iax2-provision.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/channels/iax2-provision.c (original)
+++ team/nadi/trunk-cm/channels/iax2-provision.c Fri Sep 29 03:08:06 2006
@@ -283,7 +283,7 @@
 		if (!src) {
 			src = iax_template_find(def, 0);
 			if (!src)
-				ast_log(LOG_WARNING, "Unable to locate default base template '%s' for creating '%s', omitting.", def, s);
+				ast_log(LOG_WARNING, "Unable to locate default base template '%s' for creating '%s', omitting.\n", def, s);
 		}
 		if (!src)
 			return -1;

Modified: team/nadi/trunk-cm/funcs/func_timeout.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/funcs/func_timeout.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/funcs/func_timeout.c (original)
+++ team/nadi/trunk-cm/funcs/func_timeout.c Fri Sep 29 03:08:06 2006
@@ -46,7 +46,7 @@
 	time_t myt;
 
 	if (!data) {
-		ast_log(LOG_ERROR, "Must specify type of timeout to get.");
+		ast_log(LOG_ERROR, "Must specify type of timeout to get.\n");
 		return -1;
 	}
 
@@ -76,7 +76,7 @@
 		break;
 
 	default:
-		ast_log(LOG_ERROR, "Unknown timeout type specified.");
+		ast_log(LOG_ERROR, "Unknown timeout type specified.\n");
 		break;
 	}
 
@@ -91,7 +91,7 @@
 	struct tm myt;
 
 	if (!data) {
-		ast_log(LOG_ERROR, "Must specify type of timeout to set.");
+		ast_log(LOG_ERROR, "Must specify type of timeout to set.\n");
 		return -1;
 	}
 
@@ -137,7 +137,7 @@
 		break;
 
 	default:
-		ast_log(LOG_ERROR, "Unknown timeout type specified.");
+		ast_log(LOG_ERROR, "Unknown timeout type specified.\n");
 		break;
 	}
 

Modified: team/nadi/trunk-cm/include/asterisk/lock.h
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/include/asterisk/lock.h?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/include/asterisk/lock.h (original)
+++ team/nadi/trunk-cm/include/asterisk/lock.h Fri Sep 29 03:08:06 2006
@@ -705,6 +705,8 @@
 #define ast_channel_trylock(x)		ast_mutex_trylock(&x->lock)
 #else
 
+struct ast_channel;
+
 /*! \brief Lock AST channel (and print debugging output)
 \note You need to enable DEBUG_CHANNEL_LOCKS for this function */
 int ast_channel_lock(struct ast_channel *chan);

Modified: team/nadi/trunk-cm/include/asterisk/logger.h
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/include/asterisk/logger.h?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/include/asterisk/logger.h (original)
+++ team/nadi/trunk-cm/include/asterisk/logger.h Fri Sep 29 03:08:06 2006
@@ -48,7 +48,7 @@
 /*! Used for sending a log message */
 /*!
 	\brief This is the standard logger function.  Probably the only way you will invoke it would be something like this:
-	ast_log(LOG_WHATEVER, "Problem with the %s Captain.  We should get some more.  Will %d be enough?", "flux capacitor", 10);
+	ast_log(LOG_WHATEVER, "Problem with the %s Captain.  We should get some more.  Will %d be enough?\n", "flux capacitor", 10);
 	where WHATEVER is one of ERROR, DEBUG, EVENT, NOTICE, or WARNING depending
 	on which log you wish to output to. These are implemented as macros, that
 	will provide the function with the needed arguments.

Modified: team/nadi/trunk-cm/main/cli.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/main/cli.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/main/cli.c (original)
+++ team/nadi/trunk-cm/main/cli.c Fri Sep 29 03:08:06 2006
@@ -724,8 +724,8 @@
 		"        Context: %s\n"
 		"      Extension: %s\n"
 		"       Priority: %d\n"
-		"     Call Group: %lld\n"
-		"   Pickup Group: %lld\n"
+		"     Call Group: %d\n"
+		"   Pickup Group: %d\n"
 		"    Application: %s\n"
 		"           Data: %s\n"
 		"    Blocking in: %s\n",
@@ -743,7 +743,7 @@
 		c->fout & ~DEBUGCHAN_FLAG, (c->fout & DEBUGCHAN_FLAG) ? " (DEBUGGED)" : "",
 		(long)c->whentohangup,
 		cdrtime, c->_bridge ? c->_bridge->name : "<none>", ast_bridged_channel(c) ? ast_bridged_channel(c)->name : "<none>", 
-		c->context, c->exten, c->priority, c->callgroup, c->pickupgroup, ( c->appl ? c->appl : "(N/A)" ),
+		c->context, c->exten, c->priority, (int) c->callgroup, (int) c->pickupgroup, ( c->appl ? c->appl : "(N/A)" ),
 		( c-> data ? S_OR(c->data, "(Empty)") : "(None)"),
 		(ast_test_flag(c, AST_FLAG_BLOCKING) ? c->blockproc : "(Not Blocking)"));
 	

Modified: team/nadi/trunk-cm/main/frame.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/main/frame.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/main/frame.c (original)
+++ team/nadi/trunk-cm/main/frame.c Fri Sep 29 03:08:06 2006
@@ -229,7 +229,7 @@
 	/* IF we have an optimization frame, send it */
 	if (s->opt) {
 		if (s->opt->offset < AST_FRIENDLY_OFFSET)
-			ast_log(LOG_WARNING, "Returning a frame of inappropriate offset (%d).",
+			ast_log(LOG_WARNING, "Returning a frame of inappropriate offset (%d).\n",
 							s->opt->offset);
 		opt = s->opt;
 		s->opt = NULL;

Modified: team/nadi/trunk-cm/main/pbx.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/main/pbx.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/main/pbx.c (original)
+++ team/nadi/trunk-cm/main/pbx.c Fri Sep 29 03:08:06 2006
@@ -104,6 +104,7 @@
 });
 
 struct ast_context;
+struct ast_app;
 
 /*!
    \brief ast_exten: An extension
@@ -119,6 +120,7 @@
 	const char *label;		/*!< Label */
 	struct ast_context *parent;	/*!< The context this extension belongs to  */
 	const char *app; 		/*!< Application to execute */
+	struct ast_app *cached_app;     /*!< Cached location of application */
 	void *data;			/*!< Data to use (arguments) */
 	void (*datad)(void *);		/*!< Data destructor */
 	struct ast_exten *peer;		/*!< Next higher priority with our extension */
@@ -1659,7 +1661,9 @@
 			ast_mutex_unlock(&conlock);
 			return res;	/* the priority we were looking for */
 		} else {	/* spawn */
-			app = pbx_findapp(e->app);
+			if (!e->cached_app)
+				e->cached_app = pbx_findapp(e->app);
+			app = e->cached_app;
 			ast_mutex_unlock(&conlock);
 			if (!app) {
 				ast_log(LOG_WARNING, "No application '%s' for extension (%s, %s, %d)\n", e->app, context, exten, priority);
@@ -3472,6 +3476,25 @@
 	show_dialplan_help, complete_show_dialplan_context },
 };
 
+static void unreference_cached_app(struct ast_app *app)
+{
+	struct ast_context *context = NULL;
+	struct ast_exten *eroot = NULL, *e = NULL;
+
+	ast_lock_contexts();
+	while ((context = ast_walk_contexts(context))) {
+		while ((eroot = ast_walk_context_extensions(context, eroot))) {
+			while ((e = ast_walk_extension_priorities(eroot, e))) {
+				if (e->cached_app == app)
+					e->cached_app = NULL;
+			}
+		}
+	}
+	ast_unlock_contexts();
+
+	return;
+}
+
 int ast_unregister_application(const char *app)
 {
 	struct ast_app *tmp;
@@ -3479,6 +3502,7 @@
 	AST_LIST_LOCK(&apps);
 	AST_LIST_TRAVERSE_SAFE_BEGIN(&apps, tmp, list) {
 		if (!strcasecmp(app, tmp->name)) {
+			unreference_cached_app(tmp);
 			AST_LIST_REMOVE_CURRENT(&apps, list);
 			if (option_verbose > 1)
 				ast_verbose( VERBOSE_PREFIX_2 "Unregistered application '%s'\n", tmp->name);

Modified: team/nadi/trunk-cm/main/udptl.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/main/udptl.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/main/udptl.c (original)
+++ team/nadi/trunk-cm/main/udptl.c Fri Sep 29 03:08:06 2006
@@ -712,7 +712,7 @@
 			udptl->error_correction_scheme = UDPTL_ERROR_CORRECTION_NONE;
 			break;
 		default:
-			ast_log(LOG_WARNING, "error correction parameter invalid");
+			ast_log(LOG_WARNING, "error correction parameter invalid\n");
 		};
 	} else
 		ast_log(LOG_WARNING, "udptl structure is null\n");

Modified: team/nadi/trunk-cm/res/res_monitor.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/res/res_monitor.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/res/res_monitor.c (original)
+++ team/nadi/trunk-cm/res/res_monitor.c Fri Sep 29 03:08:06 2006
@@ -338,7 +338,7 @@
 {
 	char tmp[256];
 	if (ast_strlen_zero(fname_base)) {
-		ast_log(LOG_WARNING, "Cannot change monitor filename of channel %s to null", chan->name);
+		ast_log(LOG_WARNING, "Cannot change monitor filename of channel %s to null\n", chan->name);
 		return -1;
 	}
 

Modified: team/nadi/trunk-cm/res/res_musiconhold.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/res/res_musiconhold.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/res/res_musiconhold.c (original)
+++ team/nadi/trunk-cm/res/res_musiconhold.c Fri Sep 29 03:08:06 2006
@@ -1176,7 +1176,7 @@
 		res = ast_register_application(app4, moh4_exec, synopsis4, descrip4);
 
 	if (!init_classes(0)) { 	/* No music classes configured, so skip it */
-		ast_log(LOG_WARNING, "No music on hold classes configured, disabling music on hold.");
+		ast_log(LOG_WARNING, "No music on hold classes configured, disabling music on hold.\n");
 	} else {
 		ast_install_music_functions(local_ast_moh_start, local_ast_moh_stop, local_ast_moh_cleanup);
 	}

Modified: team/nadi/trunk-cm/res/res_smdi.c
URL: http://svn.digium.com/view/asterisk/team/nadi/trunk-cm/res/res_smdi.c?rev=43974&r1=43973&r2=43974&view=diff
==============================================================================
--- team/nadi/trunk-cm/res/res_smdi.c (original)
+++ team/nadi/trunk-cm/res/res_smdi.c Fri Sep 29 03:08:06 2006
@@ -143,7 +143,7 @@
 	fclose(file);
 
 	ASTOBJ_UNLOCK(iface);
-	ast_log(LOG_DEBUG, "Sent MWI unset message for %s on %s", mailbox, iface->name);
+	ast_log(LOG_DEBUG, "Sent MWI unset message for %s on %s\n", mailbox, iface->name);
 	return 0;
 }
 
@@ -199,7 +199,7 @@
 		if (elapsed > iface->msg_expiry) {
 			/* found an expired message */
 			ASTOBJ_UNREF(md_msg, ast_smdi_md_message_destroy);
-			ast_log(LOG_NOTICE, "Purged expired message from %s SMDI MD message queue.  Message was %ld milliseconds too old.",
+			ast_log(LOG_NOTICE, "Purged expired message from %s SMDI MD message queue.  Message was %ld milliseconds too old.\n",
 				iface->name, elapsed - iface->msg_expiry);
 			md_msg = ASTOBJ_CONTAINER_UNLINK_START(&iface->md_q);
 		}
@@ -267,7 +267,7 @@
 		if (elapsed > iface->msg_expiry) {
 			/* found an expired message */
 			ASTOBJ_UNREF(mwi_msg, ast_smdi_mwi_message_destroy);
-			ast_log(LOG_NOTICE, "Purged expired message from %s SMDI MWI message queue.  Message was %ld milliseconds too old.",
+			ast_log(LOG_NOTICE, "Purged expired message from %s SMDI MWI message queue.  Message was %ld milliseconds too old.\n",
 				iface->name, elapsed - iface->msg_expiry);
 			mwi_msg = ASTOBJ_CONTAINER_UNLINK_START(&iface->mwi_q);
 		}



More information about the asterisk-commits mailing list