[asterisk-commits] oej: branch group/bufo-manager-setvar-trunk r334450 - in /team/group/bufo-man...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Sep 5 06:55:30 CDT 2011


Author: oej
Date: Mon Sep  5 06:55:13 2011
New Revision: 334450

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=334450
Log:
Reset and resolve

Modified:
    team/group/bufo-manager-setvar-trunk/   (props changed)
    team/group/bufo-manager-setvar-trunk/CHANGES
    team/group/bufo-manager-setvar-trunk/Makefile
    team/group/bufo-manager-setvar-trunk/addons/chan_mobile.c
    team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.c
    team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.h
    team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooGkClient.c
    team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/oochannels.c
    team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooh323.c
    team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooq931.c
    team/group/bufo-manager-setvar-trunk/apps/app_queue.c
    team/group/bufo-manager-setvar-trunk/apps/app_voicemail.c
    team/group/bufo-manager-setvar-trunk/build_tools/mkpkgconfig
    team/group/bufo-manager-setvar-trunk/cel/cel_odbc.c   (props changed)
    team/group/bufo-manager-setvar-trunk/channels/chan_agent.c
    team/group/bufo-manager-setvar-trunk/channels/chan_dahdi.c
    team/group/bufo-manager-setvar-trunk/channels/chan_gtalk.c
    team/group/bufo-manager-setvar-trunk/channels/chan_local.c
    team/group/bufo-manager-setvar-trunk/channels/chan_sip.c
    team/group/bufo-manager-setvar-trunk/channels/chan_vpb.cc
    team/group/bufo-manager-setvar-trunk/configs/cdr.conf.sample
    team/group/bufo-manager-setvar-trunk/configs/cel_odbc.conf.sample   (props changed)
    team/group/bufo-manager-setvar-trunk/configs/manager.conf.sample
    team/group/bufo-manager-setvar-trunk/configure
    team/group/bufo-manager-setvar-trunk/configure.ac
    team/group/bufo-manager-setvar-trunk/include/asterisk/cdr.h
    team/group/bufo-manager-setvar-trunk/include/asterisk/channel.h
    team/group/bufo-manager-setvar-trunk/include/asterisk/config.h
    team/group/bufo-manager-setvar-trunk/include/asterisk/manager.h
    team/group/bufo-manager-setvar-trunk/include/asterisk/res_fax.h
    team/group/bufo-manager-setvar-trunk/include/asterisk/test.h
    team/group/bufo-manager-setvar-trunk/main/app.c
    team/group/bufo-manager-setvar-trunk/main/cdr.c
    team/group/bufo-manager-setvar-trunk/main/channel.c
    team/group/bufo-manager-setvar-trunk/main/config.c
    team/group/bufo-manager-setvar-trunk/main/file.c
    team/group/bufo-manager-setvar-trunk/main/manager.c
    team/group/bufo-manager-setvar-trunk/main/pbx.c
    team/group/bufo-manager-setvar-trunk/main/test.c
    team/group/bufo-manager-setvar-trunk/makeopts.in
    team/group/bufo-manager-setvar-trunk/res/res_config_odbc.c
    team/group/bufo-manager-setvar-trunk/res/res_config_pgsql.c
    team/group/bufo-manager-setvar-trunk/res/res_fax.c
    team/group/bufo-manager-setvar-trunk/res/res_fax_spandsp.c
    team/group/bufo-manager-setvar-trunk/res/res_jabber.c
    team/group/bufo-manager-setvar-trunk/res/res_musiconhold.c
    team/group/bufo-manager-setvar-trunk/sounds/Makefile   (contents, props changed)

Propchange: team/group/bufo-manager-setvar-trunk/
------------------------------------------------------------------------------
    automerge = Is-there-life-off-net?

Propchange: team/group/bufo-manager-setvar-trunk/
------------------------------------------------------------------------------
Binary property 'branch-10-merged' - no diff available.

Propchange: team/group/bufo-manager-setvar-trunk/
------------------------------------------------------------------------------
    svn:mergeinfo = /trunk:332757-334358

Propchange: team/group/bufo-manager-setvar-trunk/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Mon Sep  5 06:55:13 2011
@@ -1,1 +1,1 @@
-/trunk:1-332706
+/trunk:1-334448

Modified: team/group/bufo-manager-setvar-trunk/CHANGES
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/CHANGES?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/CHANGES (original)
+++ team/group/bufo-manager-setvar-trunk/CHANGES Mon Sep  5 06:55:13 2011
@@ -18,6 +18,11 @@
    name field if CID number exists without a CID name. This change improves
    compatibility with certain device features such as Avaya IP500's directory
    lookup service.
+
+Chan_local changes
+------------------
+ * Added a manager event "LocalBridge" for local channel call bridges between
+   the two pseudo-channels created.
 
 ------------------------------------------------------------------------------
 --- Functionality changes from Asterisk 1.8 to Asterisk 10 -------------------
@@ -35,6 +40,10 @@
    The MESSAGE() dialplan function and MessageSend() application have been
    added to go along with this functionality.  More detailed usage information
    can be found on the Asterisk wiki (http://wiki.asterisk.org/).
+ * If real-time text support (T.140) is negotiated, it will be preferred for
+   sending text via the SendText application. For example, via SIP, messages
+   that were once sent via the SIP MESSAGE request would be sent via RTP if
+   T.140 text is negotiated for a call.
 
 Parking
 -------
@@ -84,6 +93,7 @@
 --------------------------
  * The filter option in cdr_adaptive_odbc now supports negating the argument,
    thus allowing records which do NOT match the specified filter.
+ * Added ability to log CONGESTION calls to CDR
 
 CODECS
 --------------------------
@@ -158,6 +168,11 @@
    channels involved with the FollowMe thread.  Use this option to improve
    compatability for a FollowMe call with certain dialplan apps, options, and
    functions.
+
+Meetme
+--------------------------
+ * Added option "k" that will automatically close the conference when there's
+   only one person left when a user exits the conference.
 
 CEL
 --------------------------

Modified: team/group/bufo-manager-setvar-trunk/Makefile
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/Makefile?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/Makefile (original)
+++ team/group/bufo-manager-setvar-trunk/Makefile Mon Sep  5 06:55:13 2011
@@ -286,7 +286,7 @@
 ifneq ($(findstring darwin,$(OSARCH)),)
   _ASTCFLAGS+=-D__Darwin__
   SOLINK=-bundle -Xlinker -macosx_version_min -Xlinker 10.4 -Xlinker -undefined -Xlinker dynamic_lookup -force_flat_namespace
-  ifeq ($(shell /usr/bin/sw_vers -productVersion | cut -c1-4),10.6)
+  ifeq ($(shell /usr/bin/sw_vers -productVersion | cut -c1-4),10.7)
     SOLINK+=/usr/lib/bundle1.o
   endif
   _ASTLDFLAGS+=-L/usr/local/lib
@@ -555,6 +555,7 @@
 	$(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/keys"
 	$(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/phoneprov"
 	$(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/static-http"
+	$(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/sounds"
 	$(INSTALL) -d "$(DESTDIR)$(ASTMANDIR)/man8"
 	$(INSTALL) -d "$(DESTDIR)$(AGI_DIR)"
 	$(INSTALL) -d "$(DESTDIR)$(ASTDBDIR)"
@@ -617,17 +618,7 @@
 	@exit 1
 endif
 
-preinstall_spaces:
-ifneq ($(MAKE_PREINSTALL),)
-	$(MAKE_PREINSTALL)
-endif
-
-postinstall_spaces:
-ifneq ($(MAKE_POSTINSTALL),)
-	$(MAKE_POSTINSTALL)
-endif
-
-install: preinstall_spaces badshell bininstall datafiles postinstall_spaces
+install: badshell bininstall datafiles
 	@if [ -x /usr/sbin/asterisk-post-install ]; then \
 		/usr/sbin/asterisk-post-install "$(DESTDIR)" . ; \
 	fi
@@ -664,32 +655,32 @@
 	$(INSTALL) -d "$(DESTDIR)$(ASTETCDIR)"
 	@for x in configs/*.adsi; do \
 		dst="$(DESTDIR)$(ASTETCDIR)/`$(BASENAME) $$x`" ; \
-		if [ -f $${dst} ] ; then \
+		if [ -f "$${dst}" ] ; then \
 			echo "Overwriting $$x" ; \
 		else \
 			echo "Installing $$x" ; \
 		fi ; \
-		$(INSTALL) -m 644 $$x "$(DESTDIR)$(ASTETCDIR)/`$(BASENAME) $$x`" ; \
+		$(INSTALL) -m 644 "$$x" "$(DESTDIR)$(ASTETCDIR)/`$(BASENAME) $$x`" ; \
 	done
 
 samples: adsi
 	@echo Installing other config files...
 	@for x in configs/*.sample; do \
 		dst="$(DESTDIR)$(ASTETCDIR)/`$(BASENAME) $$x .sample`" ;	\
-		if [ -f $${dst} ]; then \
+		if [ -f "$${dst}" ]; then \
 			if [ "$(OVERWRITE)" = "y" ]; then \
-				if cmp -s $${dst} $$x ; then \
+				if cmp -s "$${dst}" "$$x" ; then \
 					echo "Config file $$x is unchanged"; \
 					continue; \
 				fi ; \
-				mv -f $${dst} $${dst}.old ; \
+				mv -f "$${dst}" "$${dst}.old" ; \
 			else \
 				echo "Skipping config file $$x"; \
 				continue; \
 			fi ;\
 		fi ; \
 		echo "Installing file $$x"; \
-		$(INSTALL) -m 644 $$x $${dst} ;\
+		$(INSTALL) -m 644 "$$x" "$${dst}" ;\
 	done
 	if [ "$(OVERWRITE)" = "y" ]; then \
 		echo "Updating asterisk.conf" ; \
@@ -866,7 +857,7 @@
 	rm -f "$(DESTDIR)$(ASTMANDIR)/man8/safe_asterisk.8"
 	$(MAKE) -C sounds uninstall
 
-uninstall: preinstall_spaces _uninstall postinstall_spaces
+uninstall: _uninstall
 	@echo " +--------- Asterisk Uninstall Complete -----+"  
 	@echo " + Asterisk binaries, sounds, man pages,     +"  
 	@echo " + headers, modules, and firmware builds,    +"  

Modified: team/group/bufo-manager-setvar-trunk/addons/chan_mobile.c
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/addons/chan_mobile.c?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/addons/chan_mobile.c (original)
+++ team/group/bufo-manager-setvar-trunk/addons/chan_mobile.c Mon Sep  5 06:55:13 2011
@@ -1318,21 +1318,10 @@
 
 static int mbl_ast_hangup(struct mbl_pvt *pvt)
 {
-	int res = 0;
-	for (;;) {
-		if (pvt->owner) {
-			if (ast_channel_trylock(pvt->owner)) {
-				DEADLOCK_AVOIDANCE(&pvt->lock);
-			} else {
-				res = ast_hangup(pvt->owner);
-				/* no need to unlock, ast_hangup() frees the
-				 * channel */
-				break;
-			}
-		} else
-			break;
-	}
-	return res;
+	if (pvt->owner) {
+		ast_hangup(pvt->owner);
+	}
+	return 0;
 }
 
 /*!

Modified: team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.c
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.c?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.c (original)
+++ team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.c Mon Sep  5 06:55:13 2011
@@ -63,6 +63,7 @@
    } 
    memset(call, 0, sizeof(OOH323CallData));
    ast_cond_init(&call->gkWait, NULL);
+   ast_mutex_init(&call->GkLock);
    ast_mutex_init(&call->Lock);
    call->pctxt = pctxt;
    call->msgctxt = msgctxt;

Modified: team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.h
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.h?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.h (original)
+++ team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooCalls.h Mon Sep  5 06:55:13 2011
@@ -151,6 +151,7 @@
    OOCTXT               *msgctxt;
    pthread_t		callThread;
    ast_cond_t		gkWait;
+   ast_mutex_t		GkLock;
    ast_mutex_t		Lock;
    OOBOOL 		Monitor;
    OOBOOL		fsSent;

Modified: team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooGkClient.c
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooGkClient.c?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooGkClient.c (original)
+++ team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooGkClient.c Mon Sep  5 06:55:13 2011
@@ -431,7 +431,7 @@
       if(iRet != OO_OK)
       {
          OOTRACEERR1("Error: Failed to handle received RAS message\n");
-         //pGkClient->state = GkClientFailed;
+         pGkClient->state = GkClientFailed;
       }
       memReset(pctxt);
    }
@@ -1921,6 +1921,8 @@
    OOTimer *pTimer = NULL;
    char ip[20];
 
+   ast_mutex_lock(&pGkClient->Lock);
+
    /* Search call in pending calls list */
    for(x=0 ; x<pGkClient->callsPendingList.count; x++)
    {
@@ -1931,6 +1933,9 @@
          OOTRACEDBGC3("Found Pending call(%s, %s)\n", 
                       pCallAdmInfo->call->callType, 
                       pCallAdmInfo->call->callToken);
+
+         ast_mutex_lock(&pCallAdmInfo->call->GkLock);
+
          /* Populate Remote IP */
          if(pAdmissionConfirm->destCallSignalAddress.t != 
                                       T_H225TransportAddress_ipAddress)
@@ -1939,6 +1944,9 @@
                         "Gatekeeper is not an IPv4 address\n");
             OOTRACEINFO1("Ignoring ACF, will wait for timeout and retransmit "
                          "ARQ\n");
+            ast_mutex_unlock(&pCallAdmInfo->call->GkLock);
+            ast_mutex_unlock(&pGkClient->Lock);
+            ast_cond_signal(&pCallAdmInfo->call->gkWait);
             return OO_FAILED;
          }
          ipAddress = pAdmissionConfirm->destCallSignalAddress.u.ipAddress;
@@ -2000,15 +2008,15 @@
                        pCallAdmInfo->call->callToken);
 
 	 pCallAdmInfo->call->callState = OO_CALL_CONNECTING;
-         /* ooH323CallAdmitted( pCallAdmInfo->call); */
 
          dListRemove(&pGkClient->callsPendingList, pNode);
          dListAppend(&pGkClient->ctxt, &pGkClient->callsAdmittedList, 
                                                         pNode->data);
          memFreePtr(&pGkClient->ctxt, pNode);
+         ast_mutex_unlock(&pCallAdmInfo->call->GkLock);
+	 ast_mutex_unlock(&pGkClient->Lock);
 	 ast_cond_signal(&pCallAdmInfo->call->gkWait);
          return OO_OK;
-         break;
       }
       else
       {
@@ -2017,6 +2025,7 @@
    }
    OOTRACEERR1("Error: Failed to process ACF as there is no corresponding "
                "pending call\n");
+   ast_mutex_unlock(&pGkClient->Lock);
    return OO_OK;
 }
 
@@ -2029,6 +2038,8 @@
    DListNode *pNode=NULL, *pNode1=NULL;
    OOH323CallData *call=NULL;
    OOTimer *pTimer = NULL;
+
+   ast_mutex_lock(&pGkClient->Lock);
 
    /* Search call in pending calls list */
    for(x=0 ; x<pGkClient->callsPendingList.count; x++)
@@ -2046,6 +2057,7 @@
       OOTRACEWARN2("Received admission reject with request number %d can not"
                    " be matched with any pending call.\n", 
                    pAdmissionReject->requestSeqNum);
+      ast_mutex_unlock(&pGkClient->Lock);
       return OO_OK;
    }
    else{
@@ -2054,6 +2066,7 @@
       memFreePtr(&pGkClient->ctxt, pCallAdmInfo);
       memFreePtr(&pGkClient->ctxt, pNode);
    }
+   ast_mutex_lock(&pCallAdmInfo->call->GkLock);
 
    /* Delete ARQ timer */
    for(y=0; y<pGkClient->timerList.count; y++)
@@ -2118,6 +2131,8 @@
          break;
    }
 
+   ast_mutex_unlock(&pCallAdmInfo->call->GkLock);
+   ast_mutex_unlock(&pGkClient->Lock);
    ast_cond_signal(&pCallAdmInfo->call->gkWait);
    return OO_OK;   
 }

Modified: team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/oochannels.c
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/oochannels.c?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/oochannels.c (original)
+++ team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/oochannels.c Mon Sep  5 06:55:13 2011
@@ -960,6 +960,7 @@
    ast_mutex_lock(&call->Lock);
    ast_mutex_unlock(&call->Lock);
    ast_mutex_destroy(&call->Lock);
+   ast_mutex_destroy(&call->GkLock);
    ast_cond_destroy(&call->gkWait);
    pctxt = call->pctxt;
    freeContext(pctxt);

Modified: team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooh323.c
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooh323.c?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooh323.c (original)
+++ team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooh323.c Mon Sep  5 06:55:13 2011
@@ -371,7 +371,7 @@
    H225TransportAddress_ip6Address_ip *ip6 = NULL;
    Q931InformationElement* pDisplayIE=NULL;
    OOAliases *pAlias=NULL;
-   char remoteIP[2+8*4+7];
+   char remoteIP[2+8*4+7] = "";
 
    call->callReference = q931Msg->callReference;
  
@@ -529,6 +529,7 @@
      OOTRACEERR5("ERROR: Security denial remote sig IP isn't a socket ip, %s not %s "
 		     "(%s, %s)\n", remoteIP, call->remoteIP, call->callType, 
 		     call->callToken);
+     return OO_FAILED;
    }
    
    /* check for fast start */
@@ -1638,12 +1639,15 @@
       case Q931SetupMsg: /* SETUP message is received */
          OOTRACEINFO3("Received SETUP message (%s, %s)\n", call->callType,
                        call->callToken);
-         ooOnReceivedSetup(call, q931Msg);
-
+         ret = ooOnReceivedSetup(call, q931Msg);
+         if (ret != OO_OK) {
+           call->callState = OO_CALL_CLEAR;
+         } else {
+           
          /* H225 message callback */
-         if(gH323ep.h225Callbacks.onReceivedSetup)
-            ret = gH323ep.h225Callbacks.onReceivedSetup(call, q931Msg);
-
+            if(gH323ep.h225Callbacks.onReceivedSetup)
+               ret = gH323ep.h225Callbacks.onReceivedSetup(call, q931Msg);
+         }
          /* Free up the mem used by the received message, as it's processing 
             is done. 
          */
@@ -1661,23 +1665,24 @@
             if(gH323ep.gkClient->state == GkClientRegistered)
             {
                call->callState = OO_CALL_WAITING_ADMISSION;
-	       ast_mutex_lock(&call->Lock);
                ret = ooGkClientSendAdmissionRequest(gH323ep.gkClient, call, 
                                                     FALSE);
-				tv = ast_tvnow();
+		tv = ast_tvnow();
                 ts.tv_sec = tv.tv_sec + 24;
-				ts.tv_nsec = tv.tv_usec * 1000;
-                ast_cond_timedwait(&call->gkWait, &call->Lock, &ts);
+		ts.tv_nsec = tv.tv_usec * 1000;
+	        ast_mutex_lock(&call->GkLock);
+		if (call->callState == OO_CALL_WAITING_ADMISSION)
+                   ast_cond_timedwait(&call->gkWait, &call->GkLock, &ts);
                 if (call->callState == OO_CALL_WAITING_ADMISSION)
 			call->callState = OO_CALL_CLEAR;
-                ast_mutex_unlock(&call->Lock);
+                ast_mutex_unlock(&call->GkLock);
 
             }
             else {
-               /* TODO: Should send Release complete with reject reason */
                OOTRACEERR1("Error:Ignoring incoming call as not yet"
                            "registered with Gk\n");
 	       call->callState = OO_CALL_CLEAR;
+               call->callEndReason = OO_REASON_GK_UNREACHABLE;
             }
          }
 	 if (call->callState < OO_CALL_CLEAR) {

Modified: team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooq931.c
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooq931.c?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooq931.c (original)
+++ team/group/bufo-manager-setvar-trunk/addons/ooh323c/src/ooq931.c Mon Sep  5 06:55:13 2011
@@ -2266,19 +2266,24 @@
 
    if(gH323ep.gkClient && !OO_TESTFLAG(call->flags, OO_M_DISABLEGK))
    {
-     /* No need to check registration status here as it is already checked for
-        MakeCall command */
-
-     call->callState = OO_CALL_WAITING_ADMISSION;
-     ast_mutex_lock(&call->Lock);
-     ret = ooGkClientSendAdmissionRequest(gH323ep.gkClient, call, FALSE);
-	 tv = ast_tvnow();
-     ts.tv_sec = tv.tv_sec + 24;
-	 ts.tv_nsec = tv.tv_usec * 1000;
-     ast_cond_timedwait(&call->gkWait, &call->Lock, &ts);
-     if (call->callState == OO_CALL_WAITING_ADMISSION)
+     if(gH323ep.gkClient->state == GkClientRegistered) {
+       call->callState = OO_CALL_WAITING_ADMISSION;
+       ret = ooGkClientSendAdmissionRequest(gH323ep.gkClient, call, FALSE);
+       tv = ast_tvnow();
+       ts.tv_sec = tv.tv_sec + 24;
+       ts.tv_nsec = tv.tv_usec * 1000;
+       ast_mutex_lock(&call->GkLock);
+       if (call->callState == OO_CALL_WAITING_ADMISSION)
+          ast_cond_timedwait(&call->gkWait, &call->GkLock, &ts);
+       if (call->callState == OO_CALL_WAITING_ADMISSION)
 		call->callState = OO_CALL_CLEAR;
-     ast_mutex_unlock(&call->Lock);
+       ast_mutex_unlock(&call->GkLock);
+     } else {
+       OOTRACEERR1("Error:Aborting outgoing call as not yet"
+                   "registered with Gk\n");
+       call->callState = OO_CALL_CLEAR;
+       call->callEndReason = OO_REASON_GK_UNREACHABLE;
+     }
 
    }
 

Modified: team/group/bufo-manager-setvar-trunk/apps/app_queue.c
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/apps/app_queue.c?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/apps/app_queue.c (original)
+++ team/group/bufo-manager-setvar-trunk/apps/app_queue.c Mon Sep  5 06:55:13 2011
@@ -1310,7 +1310,7 @@
 static inline struct call_queue *queue_unref(struct call_queue *q)
 {
 	ao2_ref(q, -1);
-	return q;
+	return NULL;
 }
 #endif
 
@@ -1747,8 +1747,13 @@
 	ast_string_field_set(q, sound_thanks, "queue-thankyou");
 	ast_string_field_set(q, sound_reporthold, "queue-reporthold");
 
-	if ((q->sound_periodicannounce[0] = ast_str_create(32)))
+	if (!q->sound_periodicannounce[0]) {
+		q->sound_periodicannounce[0] = ast_str_create(32);
+	}
+
+	if (q->sound_periodicannounce[0]) {
 		ast_str_set(&q->sound_periodicannounce[0], 0, "queue-periodic-announce");
+	}
 
 	for (i = 1; i < MAX_PERIODIC_ANNOUNCEMENTS; i++) {
 		if (q->sound_periodicannounce[i])
@@ -2376,6 +2381,7 @@
 	return q;
 }
 
+/*! \note Returns a reference to the loaded realtime queue. */
 static struct call_queue *load_realtime_queue(const char *queuename)
 {
 	struct ast_variable *queue_vars;
@@ -2409,17 +2415,15 @@
 		}
 		if (q) {
 			prev_weight = q->weight ? 1 : 0;
+			queue_t_unref(q, "Need to find realtime queue");
 		}
 
 		ao2_lock(queues);
 
 		q = find_queue_by_name_rt(queuename, queue_vars, member_config);
-		if (member_config) {
-			ast_config_destroy(member_config);
-		}
-		if (queue_vars) {
-			ast_variables_destroy(queue_vars);
-		}
+		ast_config_destroy(member_config);
+		ast_variables_destroy(queue_vars);
+
 		/* update the use_weight value if the queue's has gained or lost a weight */ 
 		if (q) {
 			if (!q->weight && prev_weight) {
@@ -2522,6 +2526,7 @@
 			*reason = QUEUE_JOINEMPTY;
 			ao2_unlock(q);
 			ao2_unlock(queues);
+			queue_t_unref(q, "Done with realtime queue");
 			return res;
 		}
 	}
@@ -2585,6 +2590,7 @@
 	}
 	ao2_unlock(q);
 	ao2_unlock(queues);
+	queue_t_unref(q, "Done with realtime queue");
 
 	return res;
 }
@@ -7151,13 +7157,16 @@
 		 * queues which have been deleted from realtime but which have not yet
 		 * been deleted from the in-core container
 		 */
-		if (q->realtime && !(realtime_queue = load_realtime_queue(q->name))) {
-			ao2_unlock(q);
-			queue_t_unref(q, "Done with iterator");
-			continue;
-		} else if (q->realtime) {
+		if (q->realtime) {
+			realtime_queue = load_realtime_queue(q->name);
+			if (!realtime_queue) {
+				ao2_unlock(q);
+				queue_t_unref(q, "Done with iterator");
+				continue;
+			}
 			queue_t_unref(realtime_queue, "Queue is already in memory");
 		}
+
 		if (argc == 3 && strcasecmp(q->name, argv[2])) {
 			ao2_unlock(q);
 			queue_t_unref(q, "Done with iterator");
@@ -8481,11 +8490,13 @@
 	i = ao2_iterator_init(queues, 0);
 	while ((queue = ao2_iterator_next(&i))) {
 		ao2_lock(queue);
-		if (queue->realtime && !(queue_realtime = load_realtime_queue(queue->name))) {
-			ao2_unlock(queue);
-			queue_unref(queue);
-			continue;
-		} else if (queue->realtime) {
+		if (queue->realtime) {
+			queue_realtime = load_realtime_queue(queue->name);
+			if (!queue_realtime) {
+				ao2_unlock(queue);
+				queue_unref(queue);
+				continue;
+			}
 			queue_unref(queue_realtime);
 		}
 
@@ -8493,6 +8504,7 @@
 		ao2_unlock(queue);
 		queue_unref(queue);
 	}
+	ao2_iterator_destroy(&i);
 
 	return 0;
 }

Modified: team/group/bufo-manager-setvar-trunk/apps/app_voicemail.c
URL: http://svnview.digium.com/svn/asterisk/team/group/bufo-manager-setvar-trunk/apps/app_voicemail.c?view=diff&rev=334450&r1=334449&r2=334450
==============================================================================
--- team/group/bufo-manager-setvar-trunk/apps/app_voicemail.c (original)
+++ team/group/bufo-manager-setvar-trunk/apps/app_voicemail.c Mon Sep  5 06:55:13 2011
@@ -916,6 +916,7 @@
 static int is_valid_dtmf(const char *key);
 static void read_password_from_file(const char *secretfn, char *password, int passwordlen);
 static int write_password_to_file(const char *secretfn, const char *password);
+static const char *substitute_escapes(const char *value);
 
 struct ao2_container *inprocess_container;
 
@@ -1008,10 +1009,11 @@
  * - the exitcontext
  * - vmmaxsecs, vmmaxmsg, maxdeletedmsg
  * - volume gain.
+ * - emailsubject, emailbody set to NULL
  */
 static void populate_defaults(struct ast_vm_user *vmu)
 {
-	ast_copy_flags(vmu, (&globalflags), AST_FLAGS_ALL);	
+	ast_copy_flags(vmu, (&globalflags), AST_FLAGS_ALL);
 	vmu->passwordlocation = passwordlocation;
 	if (saydurationminfo) {
 		vmu->saydurationm = saydurationminfo;
@@ -1034,7 +1036,9 @@
 		vmu->maxdeletedmsg = maxdeletedmsg;
 	}
 	vmu->volgain = volgain;
+	ast_free(vmu->emailsubject);
 	vmu->emailsubject = NULL;
+	ast_free(vmu->emailbody);
 	vmu->emailbody = NULL;
 #ifdef IMAP_STORAGE
 	ast_copy_string(vmu->imapfolder, imapfolder, sizeof(vmu->imapfolder));
@@ -1058,6 +1062,12 @@
 		ast_copy_string(vmu->attachfmt, value, sizeof(vmu->attachfmt));
 	} else if (!strcasecmp(var, "serveremail")) {
 		ast_copy_string(vmu->serveremail, value, sizeof(vmu->serveremail));
+	} else if (!strcasecmp(var, "emailbody")) {
+		ast_free(vmu->emailbody);
+		vmu->emailbody = ast_strdup(substitute_escapes(value));
+	} else if (!strcasecmp(var, "emailsubject")) {
+		ast_free(vmu->emailsubject);
+		vmu->emailsubject = ast_strdup(substitute_escapes(value));
 	} else if (!strcasecmp(var, "language")) {
 		ast_copy_string(vmu->language, value, sizeof(vmu->language));
 	} else if (!strcasecmp(var, "tz")) {
@@ -1276,6 +1286,7 @@
 		ast_realtime_require_field("voicemail", "password", RQ_CHAR, strlen(password), SENTINEL);
 	}
 	if (ast_update2_realtime("voicemail", "context", vmu->context, "mailbox", vmu->mailbox, SENTINEL, "password", password, SENTINEL) > 0) {
+		ast_test_suite_event_notify("PASSWORDCHANGED", "Message: realtime engine updated with new password\r\nPasswordSource: realtime");
 		ast_copy_string(vmu->password, password, sizeof(vmu->password));
 		res = 0;
 	}
@@ -1329,9 +1340,11 @@
 		} else if (!strcasecmp(var->name, "context")) {
 			ast_copy_string(retval->context, var->value, sizeof(retval->context));
 		} else if (!strcasecmp(var->name, "emailsubject")) {
-			retval->emailsubject = ast_strdup(var->value);
+			ast_free(retval->emailsubject);
+			retval->emailsubject = ast_strdup(substitute_escapes(var->value));
 		} else if (!strcasecmp(var->name, "emailbody")) {
-			retval->emailbody = ast_strdup(var->value);
+			ast_free(retval->emailbody);
+			retval->emailbody = ast_strdup(substitute_escapes(var->value));
 #ifdef IMAP_STORAGE
 		} else if (!strcasecmp(var->name, "imapuser")) {
 			ast_copy_string(retval->imapuser, var->value, sizeof(retval->imapuser));
@@ -1442,7 +1455,11 @@
 	if (cur) {
 		/* Make a copy, so that on a reload, we have no race */
 		if ((vmu = (ivm ? ivm : ast_malloc(sizeof(*vmu))))) {
-			memcpy(vmu, cur, sizeof(*vmu));
+			*vmu = *cur;
+			if (!ivm) {
+				vmu->emailbody = ast_strdup(cur->emailbody);
+				vmu->emailsubject = ast_strdup(cur->emailsubject);
+			}
 			ast_set2_flag(vmu, !ivm, VM_ALLOCED);
 			AST_LIST_NEXT(vmu, list) = NULL;
 		}
@@ -1507,6 +1524,7 @@
 	case OPT_PWLOC_SPOOLDIR:
 		snprintf(secretfn, sizeof(secretfn), "%s%s/%s/secret.conf", VM_SPOOL_DIR, vmu->context, vmu->mailbox);
 		if (write_password_to_file(secretfn, newpassword) == 0) {
+			ast_test_suite_event_notify("PASSWORDCHANGED", "Message: secret.conf updated with new password\r\nPasswordSource: secret.conf");
 			ast_verb(4, "Writing voicemail password to file %s succeeded\n", secretfn);
 			reset_user_pw(vmu->context, vmu->mailbox, newpassword);
 			ast_copy_string(vmu->password, newpassword, sizeof(vmu->password));
@@ -1541,6 +1559,7 @@
 			}
 			/* save the results */
 			if (found) {
+				ast_test_suite_event_notify("PASSWORDCHANGED", "Message: voicemail.conf updated with new password\r\nPasswordSource: voicemail.conf");
 				reset_user_pw(vmu->context, vmu->mailbox, newpassword);
 				ast_copy_string(vmu->password, newpassword, sizeof(vmu->password));
 				ast_config_text_file_save(VOICEMAIL_CONFIG, cfg, "AppVoicemail");
@@ -1580,6 +1599,7 @@
 			}
 			/* save the results and clean things up */
 			if (found) {
+				ast_test_suite_event_notify("PASSWORDCHANGED", "Message: users.conf updated with new password\r\nPasswordSource: users.conf");
 				reset_user_pw(vmu->context, vmu->mailbox, newpassword);
 				ast_copy_string(vmu->password, newpassword, sizeof(vmu->password));
 				ast_config_text_file_save("users.conf", cfg, "AppVoicemail");
@@ -1592,7 +1612,9 @@
 {
 	char buf[255];
 	snprintf(buf, sizeof(buf), "%s %s %s %s", ext_pass_cmd, vmu->context, vmu->mailbox, newpassword);
+	ast_debug(1, "External password: %s\n",buf);
 	if (!ast_safe_system(buf)) {
+		ast_test_suite_event_notify("PASSWORDCHANGED", "Message: external script updated with new password\r\nPasswordSource: external");
 		ast_copy_string(vmu->password, newpassword, sizeof(vmu->password));
 		/* Reset the password in memory, too */
 		reset_user_pw(vmu->context, vmu->mailbox, newpassword);
@@ -1716,14 +1738,13 @@
 static void free_user(struct ast_vm_user *vmu)
 {
 	if (ast_test_flag(vmu, VM_ALLOCED)) {
-		if (vmu->emailbody != NULL) {
-			ast_free(vmu->emailbody);
-			vmu->emailbody = NULL;
-		}
-		if (vmu->emailsubject != NULL) {
-			ast_free(vmu->emailsubject);
-			vmu->emailsubject = NULL;
-		}
+
+		ast_free(vmu->emailbody);
+		vmu->emailbody = NULL;
+
+		ast_free(vmu->emailsubject);
+		vmu->emailsubject = NULL;
+
 		ast_free(vmu);
 	}
 }
@@ -6737,6 +6758,7 @@
 				d = vm_play_folder_name(chan, "vm-INBOX");
 			}
 		} else {
+			ast_test_suite_event_notify("PLAYBACK", "Message: folder name %s", fn);
 			d = vm_play_folder_name(chan, fn);
 		}
 
@@ -6746,6 +6768,7 @@
 		if (d)
 			return d;
 	}
+
 	d = ast_play_and_wait(chan, "vm-tocancel"); /* "or pound to cancel" */
 	if (d)
 		return d;
@@ -6769,6 +6792,7 @@
 {
 	int res = 0;
 	int loops = 0;
+
 	res = ast_play_and_wait(chan, fn);	/* Folder name */
 	while (((res < '0') || (res > '9')) &&
 			(res != '#') && (res >= 0) &&
@@ -6777,8 +6801,10 @@
 		loops++;
 	}
 	if (loops == 4) { /* give up */
+		ast_test_suite_event_notify("USERPRESS", "Message: User pressed %c\r\nDTMF: %c", '#', '#');
 		return '#';
 	}
+	ast_test_suite_event_notify("USERPRESS", "Message: User pressed %c\r\nDTMF: %c", res, res);
 	return res;
 }
 
@@ -6923,16 +6949,20 @@
 
 			cmd = ast_play_and_wait(chan, "vm-forwardoptions");
 				/* "Press 1 to prepend a message or 2 to forward the message without prepending" */
-			if (!cmd)
+			if (!cmd) {
 				cmd = ast_play_and_wait(chan, "vm-starmain");
 				/* "press star to return to the main menu" */
-			if (!cmd)
+			}
+			if (!cmd) {
 				cmd = ast_waitfordigit(chan, 6000);
-			if (!cmd)
+			}
+			if (!cmd) {
 				retries++;
+			}
 			if (retries > 3) {
 				cmd = '*'; /* Let's cancel this beast */
 			}
+			ast_test_suite_event_notify("USERPRESS", "Message: User pressed %c\r\nDTMF: %c", cmd, cmd);
 		}
 	}
 
@@ -7123,6 +7153,7 @@
 	dir = vms->curdir;
 	curmsg = vms->curmsg;
 
+	ast_test_suite_event_notify("FORWARD", "Message: entering forward message menu");
 	while (!res && !valid_extensions) {
 		int use_directory = 0;
 		if (ast_test_flag((&globalflags), VM_DIRECFORWARD)) {
@@ -7148,15 +7179,17 @@
 				default: 
 					/* Press 1 to enter an extension press 2 to use the directory */
 					cmd = ast_play_and_wait(chan, "vm-forward");
-					if (!cmd)
+					if (!cmd) {
 						cmd = ast_waitfordigit(chan, 3000);
-					if (!cmd)
+					}
+					if (!cmd) {
 						retries++;
+					}
 					if (retries > 3) {
 						cmd = 't';
 						done = 1;
 					}
-					
+					ast_test_suite_event_notify("USERPRESS", "Message: User pressed %c\r\nDTMF: %c", cmd, cmd);
 				}
 			}
 			if (cmd < 0 || cmd == 't')
@@ -7195,6 +7228,7 @@
 			}
 		} else {
 			/* Ask for an extension */
+			ast_test_suite_event_notify("PLAYBACK", "Message: vm-extension");
 			res = ast_streamfile(chan, "vm-extension", chan->language);	/* "extension" */
 			prompt_played++;
 			if (res || prompt_played > 4)
@@ -7401,6 +7435,7 @@
 
 static int wait_file(struct ast_channel *chan, struct vm_state *vms, char *file) 
 {
+	ast_test_suite_event_notify("PLAYVOICE", "Message: Playing %s", file);
 	return ast_control_streamfile(chan, file, listen_control_forward_key, listen_control_reverse_key, listen_control_stop_key, listen_control_pause_key, listen_control_restart_key, skipms, NULL);
 }
 
@@ -7617,10 +7652,11 @@
 	vms->starting = 0;
 	make_file(vms->fn, sizeof(vms->fn), vms->curdir, vms->curmsg);
 	adsi_message(chan, vms);
-	if (!vms->curmsg)
+	if (!vms->curmsg) {
 		res = wait_file2(chan, vms, "vm-first");	/* "First" */
-	else if (vms->curmsg == vms->lastmsg)
+	} else if (vms->curmsg == vms->lastmsg) {
 		res = wait_file2(chan, vms, "vm-last");		/* "last" */
+	}
 
 	snprintf(filename, sizeof(filename), "%s.txt", vms->fn);
 	RETRIEVE(vms->curdir, vms->curmsg, vmu->mailbox, vmu->context);
@@ -7696,6 +7732,7 @@
 			}
 			if (vms->curmsg && (vms->curmsg != vms->lastmsg)) {
 				if (!res) {
+					ast_test_suite_event_notify("PLAYBACK", "Message: message number");
 					res = ast_say_number(chan, vms->curmsg + 1, AST_DIGIT_ANY, chan->language, NULL);
 				}
 			}
@@ -7724,15 +7761,20 @@
 	if (!res) {
 		res = play_message_category(chan, category);
 	}
-	if ((!res) && (ast_test_flag(vmu, VM_ENVELOPE)))
+	if ((!res) && (ast_test_flag(vmu, VM_ENVELOPE))) {
 		res = play_message_datetime(chan, vmu, origtime, filename);
-	if ((!res) && (ast_test_flag(vmu, VM_SAYCID)))
+	}
+	if ((!res) && (ast_test_flag(vmu, VM_SAYCID))) {
 		res = play_message_callerid(chan, vms, cid, context, 0);
-	if ((!res) && (ast_test_flag(vmu, VM_SAYDURATION)))
+	}
+	if ((!res) && (ast_test_flag(vmu, VM_SAYDURATION))) {
 		res = play_message_duration(chan, vms, duration, vmu->saydurationm);
+	}
 	/* Allow pressing '1' to skip envelope / callerid */
-	if (res == '1')
+	if (res == '1') {
+		ast_test_suite_event_notify("USERPRESS", "Message: User pressed %c\r\nDTMF: %c", res, res);
 		res = 0;
+	}
 	ast_config_destroy(msg_cfg);
 
 	if (!res) {
@@ -7750,6 +7792,7 @@
 			ast_log(AST_LOG_WARNING, "Playback of message %s failed\n", vms->fn);
 			res = 0;
 		}
+		ast_test_suite_event_notify("USERPRESS", "Message: User pressed %c\r\nDTMF: %c", res, res);
 	}
 	DISPOSE(vms->curdir, vms->curmsg);
 	return res;
@@ -9135,6 +9178,7 @@
 	unsigned char buf[256];
 	int bytes = 0;
 
+	ast_test_suite_event_notify("NEWUSER", "Message: entering new user state");
 	if (ast_adsi_available(chan)) {
 		bytes += adsi_logo(buf + bytes);
 		bytes += ast_adsi_display(buf + bytes, ADSI_COMM_PAGE, 3, ADSI_JUST_CENT, 0, "New User Setup", "");
@@ -9230,6 +9274,7 @@
 	unsigned char buf[256];
 	int bytes = 0;
 
+	ast_test_suite_event_notify("VMOPTIONS", "Message: entering mailbox options");
 	if (ast_adsi_available(chan)) {
 		bytes += adsi_logo(buf + bytes);
 		bytes += ast_adsi_display(buf + bytes, ADSI_COMM_PAGE, 3, ADSI_JUST_CENT, 0, "Options Menu", "");
@@ -9302,10 +9347,13 @@
 				}
 				break;
 			}
-			if (pwdchange & PWDCHANGE_INTERNAL)
+
+			if (pwdchange & PWDCHANGE_INTERNAL) {
 				vm_change_password(vmu, newpassword);
-			if ((pwdchange & PWDCHANGE_EXTERNAL) && !ast_strlen_zero(ext_pass_cmd))
+			}
+			if ((pwdchange & PWDCHANGE_EXTERNAL) && !ast_strlen_zero(ext_pass_cmd)) {
 				vm_change_password_shell(vmu, newpassword);
+			}
 
 			ast_debug(1, "User %s set password to %s of length %d\n",
 				vms->username, newpassword, (int) strlen(newpassword));
@@ -9334,6 +9382,7 @@
 			if (retries > 3) {
 				cmd = 't';
 			}
+			ast_test_suite_event_notify("USERPRESS", "Message: User pressed %c\r\nDTMF: %c", cmd, cmd);
 		}
 	}
 	if (cmd == 't')
@@ -9375,6 +9424,7 @@
 		ast_adsi_transmit_message(chan, buf, bytes, ADSI_MSG_DISPLAY);
 	}
 
+	ast_test_suite_event_notify("TEMPGREETING", "Message: entering temp greeting options");
 	snprintf(prefile, sizeof(prefile), "%s%s/%s/temp", VM_SPOOL_DIR, vmu->context, vms->username);
 	while ((cmd >= 0) && (cmd != 't')) {
 		if (cmd)
@@ -9400,12 +9450,16 @@
 				cmd = ast_play_and_wait(chan,
 					ast_fileexists(prefile, NULL, NULL) > 0 ? /* XXX always true ? */
 						"vm-tempgreeting2" : "vm-tempgreeting");
-				if (!cmd)
+				if (!cmd) {
 					cmd = ast_waitfordigit(chan, 6000);
-				if (!cmd)
+				}
+				if (!cmd) {
 					retries++;
-				if (retries > 3)
+				}
+				if (retries > 3) {
 					cmd = 't';
+				}
+				ast_test_suite_event_notify("USERPRESS", "Message: User pressed %c\r\nDTMF: %c", cmd, cmd);
 			}
 		}
 		DISPOSE(prefile, -1);
@@ -9669,13 +9723,14 @@
 	adsi_begin(chan, &useadsi);
 	if (!skipuser && useadsi)
 		adsi_login(chan);
+	ast_test_suite_event_notify("PLAYBACK", "Message: vm-login");
 	if (!silent && !skipuser && ast_streamfile(chan, "vm-login", chan->language)) {
 		ast_log(AST_LOG_WARNING, "Couldn't stream login file\n");
 		return -1;
 	}
-	
+
 	/* Authenticate them and get their mailbox/password */
-	
+
 	while (!valid && (logretries < max_logins)) {
 		/* Prompt for, and read in the username */
 		if (!skipuser && ast_readstring(chan, mailbox, mailbox_size - 1, 2000, 10000, "#") < 0) {
@@ -9716,6 +9771,7 @@
 			/* saved password is blank, so don't bother asking */
 			password[0] = '\0';
 		} else {
+			ast_test_suite_event_notify("PLAYBACK", "Message: %s", vm_password);
 			if (ast_streamfile(chan, vm_password, chan->language)) {
 				ast_log(AST_LOG_WARNING, "Unable to stream password file\n");
 				return -1;
@@ -9752,11 +9808,13 @@
 		logretries++;
 		if (!valid) {
 			if (skipuser || logretries >= max_logins) {
+				ast_test_suite_event_notify("PLAYBACK", "Message: vm-incorrect");
 				if (ast_streamfile(chan, "vm-incorrect", chan->language)) {
 					ast_log(AST_LOG_WARNING, "Unable to stream incorrect message\n");
 					return -1;
 				}
 			} else {
+				ast_test_suite_event_notify("PLAYBACK", "Message: vm-incorrect-mailbox");
 				if (useadsi)
 					adsi_login(chan);
 				if (ast_streamfile(chan, "vm-incorrect-mailbox", chan->language)) {
@@ -9812,6 +9870,7 @@
 
 	memset(&vmus, 0, sizeof(vmus));
 
+	ast_test_suite_event_notify("START", "Message: vm_execmain started");
 	if (chan->_state != AST_STATE_UP) {
 		ast_debug(1, "Before ast_answer\n");
 		ast_answer(chan);
@@ -9906,6 +9965,7 @@
 
 		/* user entered '*' */
 		if (!ast_goto_if_exists(chan, chan->context, "a", 1)) {
+			ast_test_suite_event_notify("REDIRECT", "Message: redirecting user to 'a' extension");
 			res = 0;	/* prevent hangup */
 			goto out;
 		}
@@ -9922,9 +9982,11 @@
 	/* If ADSI is supported, setup login screen */
 	adsi_begin(chan, &useadsi);
 
+	ast_test_suite_assert(valid);
 	if (!valid) {
 		goto out;
 	}

[... 3755 lines stripped ...]



More information about the asterisk-commits mailing list