[svn-commits] mmichelson: branch group/v6-new r274095 - in /team/group/v6-new: ./ addons/ a...

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Jul 6 08:57:53 CDT 2010


Author: mmichelson
Date: Tue Jul  6 08:57:42 2010
New Revision: 274095

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=274095
Log:
Resolve conflict and reset automerge.


Modified:
    team/group/v6-new/   (props changed)
    team/group/v6-new/addons/chan_mobile.c
    team/group/v6-new/apps/app_queue.c
    team/group/v6-new/apps/app_rpt.c
    team/group/v6-new/apps/app_voicemail.c
    team/group/v6-new/apps/app_while.c
    team/group/v6-new/channels/chan_agent.c
    team/group/v6-new/channels/chan_dahdi.c
    team/group/v6-new/channels/chan_h323.c
    team/group/v6-new/channels/chan_iax2.c
    team/group/v6-new/channels/chan_local.c
    team/group/v6-new/channels/chan_mgcp.c
    team/group/v6-new/channels/chan_misdn.c
    team/group/v6-new/channels/chan_sip.c
    team/group/v6-new/include/asterisk/lock.h
    team/group/v6-new/main/autoservice.c
    team/group/v6-new/main/config.c
    team/group/v6-new/main/fixedjitterbuf.c
    team/group/v6-new/main/pbx.c
    team/group/v6-new/main/say.c
    team/group/v6-new/main/utils.c
    team/group/v6-new/main/xmldoc.c
    team/group/v6-new/res/res_agi.c

Propchange: team/group/v6-new/
------------------------------------------------------------------------------
    automerge = *

Propchange: team/group/v6-new/
------------------------------------------------------------------------------
Binary property 'branch-1.4-blocked' - no diff available.

Propchange: team/group/v6-new/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/group/v6-new/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Tue Jul  6 08:57:42 2010
@@ -1,1 +1,1 @@
-/trunk:1-270973,270975-273575
+/trunk:1-270973,270975-274093

Modified: team/group/v6-new/addons/chan_mobile.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/addons/chan_mobile.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/addons/chan_mobile.c (original)
+++ team/group/v6-new/addons/chan_mobile.c Tue Jul  6 08:57:42 2010
@@ -1242,7 +1242,7 @@
 	If the end result > 100, and it usually is if we have the problem, set a flag and compensate by shifting the bytes
 	for each subsequent frame during the call.
 
-	If the result is <= 100 then clear the flag so we dont come back in here...
+	If the result is <= 100 then clear the flag so we don't come back in here...
 
 	This seems to work OK....
 

Modified: team/group/v6-new/apps/app_queue.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/apps/app_queue.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/apps/app_queue.c (original)
+++ team/group/v6-new/apps/app_queue.c Tue Jul  6 08:57:42 2010
@@ -1188,22 +1188,27 @@
 				ast_debug(4, "%s is unavailable because his device state is 'invalid'\n", member->membername);
 				break;
 			}
+			goto default_case;
 		case AST_DEVICE_UNAVAILABLE:
 			if (conditions & QUEUE_EMPTY_UNAVAILABLE) {
 				ast_debug(4, "%s is unavailable because his device state is 'unavailable'\n", member->membername);
 				break;
 			}
+			goto default_case;
 		case AST_DEVICE_INUSE:
 			if (conditions & QUEUE_EMPTY_INUSE) {
 				ast_debug(4, "%s is unavailable because his device state is 'inuse'\n", member->membername);
 				break;
 			}
+			goto default_case;
 		case AST_DEVICE_UNKNOWN:
 			if (conditions & QUEUE_EMPTY_UNKNOWN) {
 				ast_debug(4, "%s is unavailable because his device state is 'unknown'\n", member->membername);
 				break;
 			}
+			/* Fall-through */
 		default:
+		default_case:
 			if (member->paused && (conditions & QUEUE_EMPTY_PAUSED)) {
 				ast_debug(4, "%s is unavailable because he is paused'\n", member->membername);
 				break;

Modified: team/group/v6-new/apps/app_rpt.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/apps/app_rpt.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/apps/app_rpt.c (original)
+++ team/group/v6-new/apps/app_rpt.c Tue Jul  6 08:57:42 2010
@@ -1534,7 +1534,7 @@
                        l = l->next;
                        continue;
                }
-               /* dont send to self */
+               /* don't send to self */
                if (mylink && (l == mylink))
                {
                        l = l->next;
@@ -1895,7 +1895,7 @@
 	{
 		/* if is not a real link, ignore it */
 		if (l->name[0] == '0') continue;
-		/* dont count our stuff */
+		/* don't count our stuff */
 		if (l == mylink) continue;
 		if (mylink && (!strcmp(l->name,mylink->name))) continue;
 		/* figure out mode to report */
@@ -4375,7 +4375,7 @@
 		wait_interval(myrpt, DLY_TELEM, mychannel);
 		l = myrpt->links.next;
 		haslink = 0;
-		/* dont report if a link for this one still on system */
+		/* don't report if a link for this one still on system */
 		if (l != &myrpt->links)
 		{
 			rpt_mutex_lock(&myrpt->lock);
@@ -5223,7 +5223,7 @@
 	{
 	    case UNKEY:
 		/* if any of the following are defined, go ahead and do it,
-		   otherwise, dont bother */
+		   otherwise, don't bother */
 		v1 = (char *) ast_variable_retrieve(myrpt->cfg, myrpt->name, 
 			"unlinkedct");
 		v2 = (char *) ast_variable_retrieve(myrpt->cfg, myrpt->name, 
@@ -6741,7 +6741,7 @@
 					l = l->next;
 					continue;
 				}
-				/* dont send back from where it came */
+				/* don't send back from where it came */
 				if ((l == mylink) || (!strcmp(l->name,mylink->name)))
 				{
 					l = l->next;
@@ -6772,7 +6772,7 @@
 					l = l->next;
 					continue;
 				}
-				/* dont send back from where it came */
+				/* don't send back from where it came */
 				if ((l == mylink) || (!strcmp(l->name,mylink->name)))
 				{
 					l = l->next;
@@ -6870,7 +6870,7 @@
 				l = l->next;
 				continue;
 			}
-			/* dont send back from where it came */
+			/* don't send back from where it came */
 			if ((l == mylink) || (!strcmp(l->name,mylink->name)))
 			{
 				l = l->next;
@@ -6897,7 +6897,7 @@
 				l = l->next;
 				continue;
 			}
-			/* dont send back from where it came */
+			/* don't send back from where it came */
 			if ((l == mylink) || (!strcmp(l->name,mylink->name)))
 			{
 				l = l->next;
@@ -10147,7 +10147,7 @@
 	/* if decode not active */
 	if (myrpt->dtmfidx == -1)
 	{
-		/* if not lead-in digit, dont worry */
+		/* if not lead-in digit, don't worry */
 		if (c != myrpt->p.funcchar)
 		{
 			if (!myrpt->p.propagate_dtmf)
@@ -12990,7 +12990,7 @@
 	{
 		load_rpt_vars(i,1);
 
-		/* if is a remote, dont start one for it */
+		/* if is a remote, don't start one for it */
 		if (rpt_vars[i].remote)
 		{
 			if(retreive_memory(&rpt_vars[i],"init")){ /* Try to retreive initial memory channel */
@@ -14337,7 +14337,7 @@
 			if (handle_remote_dtmf_digit(myrpt,c,&keyed,0) == -1) break;
 			continue;
 		} else rpt_mutex_unlock(&myrpt->lock);
-		if (who == chan) /* if it was a read from incomming */
+		if (who == chan) /* if it was a read from incoming */
 		{
 			f = ast_read(chan);
 			if (!f)

Modified: team/group/v6-new/apps/app_voicemail.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/apps/app_voicemail.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/apps/app_voicemail.c (original)
+++ team/group/v6-new/apps/app_voicemail.c Tue Jul  6 08:57:42 2010
@@ -4650,7 +4650,7 @@
 				attach = newtmp;
 				ast_debug(3, "VOLGAIN: Stored at: %s.%s - Level: %.4f - Mailbox: %s\n", attach, format, vmu->volgain, mailbox);
 			} else {
-				ast_log(LOG_WARNING, "Sox failed to reencode %s.%s: %s (have you installed support for all sox file formats?)\n", attach, format,
+				ast_log(LOG_WARNING, "Sox failed to re-encode %s.%s: %s (have you installed support for all sox file formats?)\n", attach, format,
 					soxstatus == 1 ? "Problem with command line options" : "An error occurred during file processing");
 				ast_log(LOG_WARNING, "Voicemail attachment will have no volume gain.\n");
 			}

Modified: team/group/v6-new/apps/app_while.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/apps/app_while.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/apps/app_while.c (original)
+++ team/group/v6-new/apps/app_while.c Tue Jul  6 08:57:42 2010
@@ -204,7 +204,7 @@
 	}
 
 #if 0
-	/* dont want run away loops if the chan isn't even up
+	/* don't want run away loops if the chan isn't even up
 	   this is up for debate since it slows things down a tad ......
 
 	   Debate is over... this prevents While/EndWhile from working

Modified: team/group/v6-new/channels/chan_agent.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/channels/chan_agent.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/channels/chan_agent.c (original)
+++ team/group/v6-new/channels/chan_agent.c Tue Jul  6 08:57:42 2010
@@ -715,7 +715,12 @@
 	ast_mutex_lock(&p->lock);
 	if (p->chan && !ast_check_hangup(p->chan)) {
 		while (ast_channel_trylock(p->chan)) {
-			ast_channel_unlock(ast);
+			int res;
+			if ((res = ast_channel_unlock(ast))) {
+				ast_log(LOG_ERROR, "chan_agent bug! Channel was not locked upon entry to agent_indicate: %s\n", strerror(res));
+				ast_mutex_unlock(&p->lock);
+				return -1;
+			}
 			usleep(1);
 			ast_channel_lock(ast);
 		}

Modified: team/group/v6-new/channels/chan_dahdi.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/channels/chan_dahdi.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/channels/chan_dahdi.c (original)
+++ team/group/v6-new/channels/chan_dahdi.c Tue Jul  6 08:57:42 2010
@@ -1676,7 +1676,7 @@
 	/* We must have a ring by now, so, if configured, lets try to listen for
 	 * distinctive ringing */
 	if ((checkaftercid && distinctiveringaftercid) || !checkaftercid) {
-		/* Clear the current ring data array so we dont have old data in it. */
+		/* Clear the current ring data array so we don't have old data in it. */
 		for (receivedRingT = 0; receivedRingT < ARRAY_LEN(ringdata); receivedRingT++)
 			ringdata[receivedRingT] = 0;
 		receivedRingT = 0;
@@ -6408,7 +6408,7 @@
 			p->mate = 1;
 			break;
 		}
-		if (!p->tdd) { /* if we dont have one yet */
+		if (!p->tdd) { /* if we don't have one yet */
 			p->tdd = tdd_new(); /* allocate one */
 		}
 		break;
@@ -6467,10 +6467,10 @@
 	case AST_OPTION_ECHOCAN:
 		cp = (char *) data;
 		if (*cp) {
-			ast_debug(1, "Enabling echo cancelation on %s\n", chan->name);
+			ast_debug(1, "Enabling echo cancellation on %s\n", chan->name);
 			dahdi_enable_ec(p);
 		} else {
-			ast_debug(1, "Disabling echo cancelation on %s\n", chan->name);
+			ast_debug(1, "Disabling echo cancellation on %s\n", chan->name);
 			dahdi_disable_ec(p);
 		}
 		break;
@@ -8364,7 +8364,7 @@
 
 	/* Hang up if we don't really exist */
 	if (idx < 0)	{
-		ast_log(LOG_WARNING, "We dont exist?\n");
+		ast_log(LOG_WARNING, "We don't exist?\n");
 		ast_mutex_unlock(&p->lock);
 		return NULL;
 	}
@@ -9962,7 +9962,7 @@
 					if (p->usedistinctiveringdetection) {
 						len = 0;
 						distMatches = 0;
-						/* Clear the current ring data array so we dont have old data in it. */
+						/* Clear the current ring data array so we don't have old data in it. */
 						for (receivedRingT = 0; receivedRingT < ARRAY_LEN(curRingData); receivedRingT++)
 							curRingData[receivedRingT] = 0;
 						receivedRingT = 0;
@@ -10112,7 +10112,7 @@
 					samples = 0;
 					len = 0;
 					distMatches = 0;
-					/* Clear the current ring data array so we dont have old data in it. */
+					/* Clear the current ring data array so we don't have old data in it. */
 					for (receivedRingT = 0; receivedRingT < ARRAY_LEN(curRingData); receivedRingT++)
 						curRingData[receivedRingT] = 0;
 					receivedRingT = 0;
@@ -10198,7 +10198,7 @@
 						ast_debug(1, "CallerID number: %s, name: %s, flags=%d\n", number, name, flags);
 					}
 					if (distinctiveringaftercid == 1) {
-						/* Clear the current ring data array so we dont have old data in it. */
+						/* Clear the current ring data array so we don't have old data in it. */
 						for (receivedRingT = 0; receivedRingT < 3; receivedRingT++) {
 							curRingData[receivedRingT] = 0;
 						}
@@ -12022,7 +12022,7 @@
 				p.debouncetime = conf->timing.debouncetime;
 		}
 
-		/* dont set parms on a pseudo-channel */
+		/* don't set parms on a pseudo-channel */
 		if (tmp->subs[SUB_REAL].dfd >= 0)
 		{
 			res = ioctl(tmp->subs[SUB_REAL].dfd, DAHDI_SET_PARAMS, &p);
@@ -17502,7 +17502,7 @@
 		ast_log(LOG_WARNING, "Huh?  I don't exist?\n");
 		return -1;
 	}
-	if (!text[0]) return(0); /* if nothing to send, dont */
+	if (!text[0]) return(0); /* if nothing to send, don't */
 	if ((!p->tdd) && (!p->mate)) return(0);  /* if not in TDD mode, just return */
 	if (p->mate)
 		buf = ast_malloc(((strlen(text) + 1) * ASCII_BYTES_PER_CHAR) + END_SILENCE_LEN + HEADER_LEN);

Modified: team/group/v6-new/channels/chan_h323.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/channels/chan_h323.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/channels/chan_h323.c (original)
+++ team/group/v6-new/channels/chan_h323.c Tue Jul  6 08:57:42 2010
@@ -137,7 +137,7 @@
 static int gatekeeper_disable = 1;
 static int gatekeeper_discover = 0;
 static int gkroute = 0;
-/* Find user by alias (h.323 id) is default, alternative is the incomming call's source IP address*/
+/* Find user by alias (h.323 id) is default, alternative is the incoming call's source IP address*/
 static int userbyalias = 1;
 static int acceptAnonymous = 1;
 static unsigned int tos = 0;
@@ -306,7 +306,7 @@
 	if (pvt) {
 		ast_mutex_lock(&pvt->lock);
 		/* Don't hold pvt lock while trying to lock the channel */
-		while(pvt->owner && ast_channel_trylock(pvt->owner)) {
+		while (pvt->owner && ast_channel_trylock(pvt->owner)) {
 			DEADLOCK_AVOIDANCE(&pvt->lock);
 		}
 

Modified: team/group/v6-new/channels/chan_iax2.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/channels/chan_iax2.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/channels/chan_iax2.c (original)
+++ team/group/v6-new/channels/chan_iax2.c Tue Jul  6 08:57:42 2010
@@ -5812,7 +5812,7 @@
 					ast_debug(1, "predicted timestamp skew (%u) > max (%u), using real ts instead.\n",
 						abs(ms - p->nextpred), MAX_TIMESTAMP_SKEW);
 
-				if (f->samples >= rate) /* check to make sure we dont core dump */
+				if (f->samples >= rate) /* check to make sure we don't core dump */
 				{
 					int diff = ms % (f->samples / rate);
 					if (diff)
@@ -7703,7 +7703,7 @@
 		user = user_unref(user);
 	}
 	if (ast_test_flag64(p, IAX_FORCE_ENCRYPT) && !p->encmethods) { 
-		ast_log(LOG_NOTICE, "Call Terminated, Incomming call is unencrypted while force encrypt is enabled.");
+		ast_log(LOG_NOTICE, "Call Terminated, Incoming call is unencrypted while force encrypt is enabled.");
 		return res;
 	}
 	if (!ast_test_flag(&p->state, IAX_STATE_AUTHENTICATED))

Modified: team/group/v6-new/channels/chan_local.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/channels/chan_local.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/channels/chan_local.c (original)
+++ team/group/v6-new/channels/chan_local.c Tue Jul  6 08:57:42 2010
@@ -250,7 +250,11 @@
 
 	/* Ensure that we have both channels locked */
 	while (other && ast_channel_trylock(other)) {
-		ast_mutex_unlock(&p->lock);
+		int res;
+		if ((res = ast_mutex_unlock(&p->lock))) {
+			ast_log(LOG_ERROR, "chan_local bug! '&p->lock' was not locked when entering local_queue_frame! (%s)\n", strerror(res));
+			return -1;
+		}
 		if (us && us_locked) {
 			do {
 				CHANNEL_DEADLOCK_AVOIDANCE(us);

Modified: team/group/v6-new/channels/chan_mgcp.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/channels/chan_mgcp.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/channels/chan_mgcp.c (original)
+++ team/group/v6-new/channels/chan_mgcp.c Tue Jul  6 08:57:42 2010
@@ -2543,7 +2543,7 @@
 				snprintf(tmp, sizeof(tmp), ", dq-gi:%x", sub->gate->gateid);
 				strncat(local, tmp, sizeof(local) - strlen(local) - 1);
 			} else {
-					/* we still dont have gateid wait */
+					/* we still don't have gateid wait */
 				return 0;
 			}
 		}
@@ -3359,7 +3359,7 @@
 				mgcp_queue_hangup(sub);
 			}
 			transmit_response(sub, "200", req, "OK");
-			/* We dont send NTFY or AUEP to wildcard ep */
+			/* We don't send NTFY or AUEP to wildcard ep */
 			if (strcmp(p->name, p->parent->wcardep) != 0) {
 				transmit_notify_request(sub, "");
 				/* Audit endpoint.

Modified: team/group/v6-new/channels/chan_misdn.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/channels/chan_misdn.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/channels/chan_misdn.c (original)
+++ team/group/v6-new/channels/chan_misdn.c Tue Jul  6 08:57:42 2010
@@ -2363,7 +2363,7 @@
 		party->TypeOfNumber = misdn_to_PartyNumber_ton_private(id->number_type);
 		break;
 	default:
-		party->TypeOfNumber = 0;/* Dont't care */
+		party->TypeOfNumber = 0;/* Don't care */
 		break;
 	}
 }
@@ -10903,9 +10903,9 @@
 		"    a - Have Asterisk detect DTMF tones on called channel\n"
 		"    c - Make crypted outgoing call, optarg is keyindex\n"
 		"    d - Send display text to called phone, text is the optarg\n"
-		"    e - Perform echo cancelation on this channel,\n"
+		"    e - Perform echo cancellation on this channel,\n"
 		"        takes taps as optarg (32,64,128,256)\n"
-		"   e! - Disable echo cancelation on this channel\n"
+		"   e! - Disable echo cancellation on this channel\n"
 		"    f - Enable fax detection\n"
 		"    h - Make digital outgoing call\n"
 		"   h1 - Make HDLC mode digital outgoing call\n"

Modified: team/group/v6-new/channels/chan_sip.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/channels/chan_sip.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/channels/chan_sip.c (original)
+++ team/group/v6-new/channels/chan_sip.c Tue Jul  6 08:57:42 2010
@@ -7140,7 +7140,7 @@
 	/* We do not respond to responses for dialogs that we don't know about, we just drop
 	   the session quickly */
 	if (intended_method == SIP_RESPONSE)
-		ast_debug(2, "That's odd...  Got a response on a call we dont know about. Callid %s\n", callid ? callid : "<unknown>");
+		ast_debug(2, "That's odd...  Got a response on a call we don't know about. Callid %s\n", callid ? callid : "<unknown>");
 
 	return NULL;
 }
@@ -9745,7 +9745,7 @@
 	if (p->rtp) {
 		struct ast_codec_pref *pref = &ast_rtp_instance_get_codecs(p->rtp)->pref;
 		fmt = ast_codec_pref_getsize(pref, codec);
-	} else /* I dont see how you couldn't have p->rtp, but good to check for and error out if not there like earlier code */
+	} else /* I don't see how you couldn't have p->rtp, but good to check for and error out if not there like earlier code */
 		return;
 	ast_str_append(m_buf, 0, " %d", rtp_code);
 	ast_str_append(a_buf, 0, "a=rtpmap:%d %s/%d\r\n", rtp_code,
@@ -12929,7 +12929,7 @@
 		return AUTH_CHALLENGE_SENT;
 	}
 	if (good_response) {
-		append_history(p, "AuthOK", "Auth challenge succesful for %s", username);
+		append_history(p, "AuthOK", "Auth challenge successful for %s", username);
 		return AUTH_SUCCESSFUL;
 	}
 
@@ -18754,7 +18754,7 @@
 		}
 		
 		r->regstate = REG_STATE_REGISTERED;
-		r->regtime = ast_tvnow();		/* Reset time of last succesful registration */
+		r->regtime = ast_tvnow();		/* Reset time of last successful registration */
 		manager_event(EVENT_FLAG_SYSTEM, "Registry", "ChannelType: SIP\r\nDomain: %s\r\nStatus: %s\r\n", r->hostname, regstate2str(r->regstate));
 		r->regattempts = 0;
 		ast_debug(1, "Registration successful\n");
@@ -19252,7 +19252,7 @@
 					}
 				}
 			} else
-				ast_log(LOG_NOTICE, "Dont know how to handle a %d %s response from %s\n", resp, rest, p->owner ? p->owner->name : ast_sockaddr_stringify(&p->sa));
+				ast_log(LOG_NOTICE, "Don't know how to handle a %d %s response from %s\n", resp, rest, p->owner ? p->owner->name : ast_inet_ntoa(p->sa.sin_addr));
 		}
 	} else {	
 		/* Responses to OUTGOING SIP requests on INCOMING calls
@@ -20810,7 +20810,7 @@
 			}
 		}
 
-		/* We have a succesful authentication, process the SDP portion if there is one */
+		/* We have a successful authentication, process the SDP portion if there is one */
 		if (find_sdp(req)) {
 			if (process_sdp(p, req, SDP_T38_INITIATE)) {
 				/* Unacceptable codecs */

Modified: team/group/v6-new/include/asterisk/lock.h
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/include/asterisk/lock.h?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/include/asterisk/lock.h (original)
+++ team/group/v6-new/include/asterisk/lock.h Tue Jul  6 08:57:42 2010
@@ -60,6 +60,7 @@
 #endif
 
 #include "asterisk/logger.h"
+#include "asterisk/compiler.h"
 
 #define AST_PTHREADT_NULL (pthread_t) -1
 #define AST_PTHREADT_STOP (pthread_t) -2
@@ -339,12 +340,20 @@
 		char __filename[80], __func[80], __mutex_name[80]; \
 		int __lineno; \
 		int __res = ast_find_lock_info(ao2_object_get_lockaddr(chan), __filename, sizeof(__filename), &__lineno, __func, sizeof(__func), __mutex_name, sizeof(__mutex_name)); \
-		ast_channel_unlock(chan); \
+		int __res2 = ast_channel_unlock(chan); \
 		usleep(1); \
 		if (__res < 0) { /* Shouldn't ever happen, but just in case... */ \
-			ast_channel_lock(chan); \
+			if (__res2) { \
+				ast_log(LOG_WARNING, "Could not unlock channel '%s': %s and no lock info found!  I will NOT try to relock.\n", #chan, strerror(__res2)); \
+			} else { \
+				ast_channel_lock(chan); \
+			} \
 		} else { \
-			__ao2_lock(chan, __filename, __func, __lineno, __mutex_name); \
+			if (__res2) { \
+				ast_log(LOG_WARNING, "Could not unlock channel '%s': %s.  {{{Originally locked at %s line %d: (%s) '%s'}}}  I will NOT try to relock.\n", #chan, strerror(__res2), __filename, __lineno, __func, __mutex_name); \
+			} else { \
+				__ao2_lock(chan, __filename, __func, __lineno, __mutex_name); \
+			} \
 		} \
 	} while (0)
 
@@ -353,12 +362,20 @@
 		char __filename[80], __func[80], __mutex_name[80]; \
 		int __lineno; \
 		int __res = ast_find_lock_info(lock, __filename, sizeof(__filename), &__lineno, __func, sizeof(__func), __mutex_name, sizeof(__mutex_name)); \
-		ast_mutex_unlock(lock); \
+		int __res2 = ast_mutex_unlock(lock); \
 		usleep(1); \
 		if (__res < 0) { /* Shouldn't ever happen, but just in case... */ \
-			ast_mutex_lock(lock); \
+			if (__res2 == 0) { \
+				ast_mutex_lock(lock); \
+			} else { \
+				ast_log(LOG_WARNING, "Could not unlock mutex '%s': %s and no lock info found!  I will NOT try to relock.\n", #lock, strerror(__res2)); \
+			} \
 		} else { \
-			__ast_pthread_mutex_lock(__filename, __lineno, __func, __mutex_name, lock); \
+			if (__res2 == 0) { \
+				__ast_pthread_mutex_lock(__filename, __lineno, __func, __mutex_name, lock); \
+			} else { \
+				ast_log(LOG_WARNING, "Could not unlock mutex '%s': %s.  {{{Originally locked at %s line %d: (%s) '%s'}}}  I will NOT try to relock.\n", #lock, strerror(__res2), __filename, __lineno, __func, __mutex_name); \
+			} \
 		} \
 	} while (0)
 
@@ -379,7 +396,7 @@
 		char __filename[80], __func[80], __mutex_name[80]; \
 		int __lineno; \
 		int __res = ast_find_lock_info(lock, __filename, sizeof(__filename), &__lineno, __func, sizeof(__func), __mutex_name, sizeof(__mutex_name)); \
-		ast_mutex_unlock(lock);
+		int __res2 = ast_mutex_unlock(lock);
 
 /*!
  * \brief Deadlock avoidance lock
@@ -395,9 +412,17 @@
  */
 #define DLA_LOCK(lock) \
 		if (__res < 0) { /* Shouldn't ever happen, but just in case... */ \
-			ast_mutex_lock(lock); \
+			if (__res2) { \
+				ast_log(LOG_WARNING, "Could not unlock mutex '%s': %s and no lock info found!  I will NOT try to relock.\n", #lock, strerror(__res2)); \
+			} else { \
+				ast_mutex_lock(lock); \
+			} \
 		} else { \
-			__ast_pthread_mutex_lock(__filename, __lineno, __func, __mutex_name, lock); \
+			if (__res2) { \
+				ast_log(LOG_WARNING, "Could not unlock mutex '%s': %s.  {{{Originally locked at %s line %d: (%s) '%s'}}}  I will NOT try to relock.\n", #lock, strerror(__res2), __filename, __lineno, __func, __mutex_name); \
+			} else { \
+				__ast_pthread_mutex_lock(__filename, __lineno, __func, __mutex_name, lock); \
+			} \
 		} \
 	} while (0)
 
@@ -447,9 +472,15 @@
 	ast_channel_lock(chan);
 
 #define	DEADLOCK_AVOIDANCE(lock) \
-	ast_mutex_unlock(lock); \
-	usleep(1); \
-	ast_mutex_lock(lock);
+	do { \
+		int __res; \
+		if (!(__res = ast_mutex_unlock(lock))) { \
+			usleep(1); \
+			ast_mutex_lock(lock); \
+		} else { \
+			ast_log(LOG_WARNING, "Failed to unlock mutex '%s' (%s).  I will NOT try to relock. {{{ THIS IS A BUG. }}}\n", #lock, strerror(__res)); \
+		} \
+	} while (0)
 
 #define DLA_UNLOCK(lock) ast_mutex_unlock(lock)
 

Modified: team/group/v6-new/main/autoservice.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/main/autoservice.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/main/autoservice.c (original)
+++ team/group/v6-new/main/autoservice.c Tue Jul  6 08:57:42 2010
@@ -110,6 +110,11 @@
 		AST_LIST_UNLOCK(&aslist);
 
 		if (!x) {
+			/* If we don't sleep, this becomes a busy loop, which causes
+			 * problems when Asterisk runs at a different priority than other
+			 * user processes.  As long as we check for new channels at least
+			 * once every 10ms, we should be fine. */
+			usleep(10000);
 			continue;
 		}
 

Modified: team/group/v6-new/main/config.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/main/config.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/main/config.c (original)
+++ team/group/v6-new/main/config.c Tue Jul  6 08:57:42 2010
@@ -2475,9 +2475,8 @@
 	if (!config_engine_list) {
 		ast_cli(a->fd, "No config mappings found.\n");
 	} else {
-		ast_cli(a->fd, "\n\n");
 		for (eng = config_engine_list; eng; eng = eng->next) {
-			ast_cli(a->fd, "\nConfig Engine: %s\n", eng->name);
+			ast_cli(a->fd, "Config Engine: %s\n", eng->name);
 			for (map = config_maps; map; map = map->next) {
 				if (!strcasecmp(map->driver, eng->name)) {
 					ast_cli(a->fd, "===> %s (db=%s, table=%s)\n", map->name, map->database,
@@ -2485,7 +2484,6 @@
 				}
 			}
 		}
-		ast_cli(a->fd,"\n\n");
 	}
 	
 	ast_mutex_unlock(&config_lock);

Modified: team/group/v6-new/main/fixedjitterbuf.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/main/fixedjitterbuf.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/main/fixedjitterbuf.c (original)
+++ team/group/v6-new/main/fixedjitterbuf.c Tue Jul  6 08:57:42 2010
@@ -105,7 +105,7 @@
 	/* First copy our config */
 	memcpy(&jb->conf, conf, sizeof(struct fixed_jb_conf));
 
-	/* we dont need the passed config anymore - continue working with the saved one */
+	/* we don't need the passed config anymore - continue working with the saved one */
 	conf = &jb->conf;
 	
 	/* validate the configuration */

Modified: team/group/v6-new/main/pbx.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/main/pbx.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/main/pbx.c (original)
+++ team/group/v6-new/main/pbx.c Tue Jul  6 08:57:42 2010
@@ -745,7 +745,7 @@
 	</function>
 	<manager name="ShowDialPlan" language="en_US">
 		<synopsis>
-			La merde se produit.
+			Show dialplan contexts and extensions
 		</synopsis>
 		<syntax>
 			<xi:include xpointer="xpointer(/docs/manager[@name='Login']/syntax/parameter[@name='ActionID'])" />

Modified: team/group/v6-new/main/say.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/main/say.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/main/say.c (original)
+++ team/group/v6-new/main/say.c Tue Jul  6 08:57:42 2010
@@ -668,7 +668,7 @@
 					default : options = "m"; /* others are male */
 				}
 			}
-			if ( left > 1 )	{ /* we dont say "one thousand" but only thousand */
+			if ( left > 1 )	{ /* we don't say "one thousand" but only thousand */
 				res = ast_say_number_full_cs(chan, left, ints, language, options, audiofd, ctrlfd);
 				if (res) 
 					return res;
@@ -3997,7 +3997,7 @@
 				}
 				break;
 			case 'H':
-				/* 24-Hour, single digit hours preceeded by "oh" (0) */
+				/* 24-Hour, single digit hours preceded by "oh" (0) */
 				if (tm.tm_hour < 10 && tm.tm_hour > 0) {
 					res = wait_file(chan, ints, "digits/0", lang);
 				}

Modified: team/group/v6-new/main/utils.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/main/utils.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/main/utils.c (original)
+++ team/group/v6-new/main/utils.c Tue Jul  6 08:57:42 2010
@@ -283,7 +283,7 @@
 			cnt++;
 		}
 	}
-	/* Dont worry about left over bits, they're extra anyway */
+	/* Don't worry about left over bits, they're extra anyway */
 	return cnt;
 }
 

Modified: team/group/v6-new/main/xmldoc.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/main/xmldoc.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/main/xmldoc.c (original)
+++ team/group/v6-new/main/xmldoc.c Tue Jul  6 08:57:42 2010
@@ -449,7 +449,7 @@
 		}
 	}
 
-	/* remove last spaces (we dont want always to remove the trailing spaces). */
+	/* remove last spaces (we don't want always to remove the trailing spaces). */
 	if (lastspaces) {
 		ast_str_trim_blanks(*output);
 	}

Modified: team/group/v6-new/res/res_agi.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/res/res_agi.c?view=diff&rev=274095&r1=274094&r2=274095
==============================================================================
--- team/group/v6-new/res/res_agi.c (original)
+++ team/group/v6-new/res/res_agi.c Tue Jul  6 08:57:42 2010
@@ -371,7 +371,7 @@
 			to the offset without exceeding the end of the file. <replaceable>silence</replaceable> is
 			the number of seconds of silence allowed before the function returns despite the
 			lack of dtmf digits or reaching <replaceable>timeout</replaceable>. <replaceable>silence</replaceable>
-			value must be preceeded by <literal>s=</literal> and is also optional.</para>
+			value must be preceded by <literal>s=</literal> and is also optional.</para>
 		</description>
 	</agi>
 	<agi name="say alpha" language="en_US">




More information about the svn-commits mailing list