[asterisk-commits] kmoore: branch kmoore/event_system_strip r395850 - in /team/kmoore/event_syst...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Jul 31 08:10:31 CDT 2013


Author: kmoore
Date: Wed Jul 31 08:10:29 2013
New Revision: 395850

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=395850
Log:
Resolve merge conflict

Added:
    team/kmoore/event_system_strip/channels/chan_pjsip.c
      - copied unchanged from r395837, trunk/channels/chan_pjsip.c
    team/kmoore/event_system_strip/configs/pjsip.conf.sample
      - copied unchanged from r395837, trunk/configs/pjsip.conf.sample
    team/kmoore/event_system_strip/include/asterisk/res_pjsip.h
      - copied unchanged from r395837, trunk/include/asterisk/res_pjsip.h
    team/kmoore/event_system_strip/include/asterisk/res_pjsip_exten_state.h
      - copied unchanged from r395837, trunk/include/asterisk/res_pjsip_exten_state.h
    team/kmoore/event_system_strip/include/asterisk/res_pjsip_pubsub.h
      - copied unchanged from r395837, trunk/include/asterisk/res_pjsip_pubsub.h
    team/kmoore/event_system_strip/include/asterisk/res_pjsip_session.h
      - copied unchanged from r395837, trunk/include/asterisk/res_pjsip_session.h
    team/kmoore/event_system_strip/res/res_pjsip/   (props changed)
      - copied from r395837, trunk/res/res_pjsip/
    team/kmoore/event_system_strip/res/res_pjsip.c
      - copied unchanged from r395837, trunk/res/res_pjsip.c
    team/kmoore/event_system_strip/res/res_pjsip.exports.in
      - copied unchanged from r395837, trunk/res/res_pjsip.exports.in
    team/kmoore/event_system_strip/res/res_pjsip_acl.c
      - copied unchanged from r395837, trunk/res/res_pjsip_acl.c
    team/kmoore/event_system_strip/res/res_pjsip_authenticator_digest.c
      - copied unchanged from r395837, trunk/res/res_pjsip_authenticator_digest.c
    team/kmoore/event_system_strip/res/res_pjsip_caller_id.c
      - copied unchanged from r395837, trunk/res/res_pjsip_caller_id.c
    team/kmoore/event_system_strip/res/res_pjsip_diversion.c
      - copied unchanged from r395837, trunk/res/res_pjsip_diversion.c
    team/kmoore/event_system_strip/res/res_pjsip_dtmf_info.c
      - copied unchanged from r395837, trunk/res/res_pjsip_dtmf_info.c
    team/kmoore/event_system_strip/res/res_pjsip_endpoint_identifier_anonymous.c
      - copied unchanged from r395837, trunk/res/res_pjsip_endpoint_identifier_anonymous.c
    team/kmoore/event_system_strip/res/res_pjsip_endpoint_identifier_constant.c
      - copied unchanged from r395837, trunk/res/res_pjsip_endpoint_identifier_constant.c
    team/kmoore/event_system_strip/res/res_pjsip_endpoint_identifier_ip.c
      - copied unchanged from r395837, trunk/res/res_pjsip_endpoint_identifier_ip.c
    team/kmoore/event_system_strip/res/res_pjsip_endpoint_identifier_user.c
      - copied unchanged from r395837, trunk/res/res_pjsip_endpoint_identifier_user.c
    team/kmoore/event_system_strip/res/res_pjsip_exten_state.c
      - copied unchanged from r395837, trunk/res/res_pjsip_exten_state.c
    team/kmoore/event_system_strip/res/res_pjsip_exten_state.exports.in
      - copied unchanged from r395837, trunk/res/res_pjsip_exten_state.exports.in
    team/kmoore/event_system_strip/res/res_pjsip_logger.c
      - copied unchanged from r395837, trunk/res/res_pjsip_logger.c
    team/kmoore/event_system_strip/res/res_pjsip_messaging.c
      - copied unchanged from r395837, trunk/res/res_pjsip_messaging.c
    team/kmoore/event_system_strip/res/res_pjsip_mwi.c
      - copied unchanged from r395837, trunk/res/res_pjsip_mwi.c
    team/kmoore/event_system_strip/res/res_pjsip_nat.c
      - copied unchanged from r395837, trunk/res/res_pjsip_nat.c
    team/kmoore/event_system_strip/res/res_pjsip_notify.c
      - copied unchanged from r395837, trunk/res/res_pjsip_notify.c
    team/kmoore/event_system_strip/res/res_pjsip_one_touch_record_info.c
      - copied unchanged from r395837, trunk/res/res_pjsip_one_touch_record_info.c
    team/kmoore/event_system_strip/res/res_pjsip_outbound_authenticator_digest.c
      - copied unchanged from r395837, trunk/res/res_pjsip_outbound_authenticator_digest.c
    team/kmoore/event_system_strip/res/res_pjsip_outbound_registration.c
      - copied unchanged from r395837, trunk/res/res_pjsip_outbound_registration.c
    team/kmoore/event_system_strip/res/res_pjsip_pidf.c
      - copied unchanged from r395837, trunk/res/res_pjsip_pidf.c
    team/kmoore/event_system_strip/res/res_pjsip_pubsub.c
      - copied unchanged from r395837, trunk/res/res_pjsip_pubsub.c
    team/kmoore/event_system_strip/res/res_pjsip_pubsub.exports.in
      - copied unchanged from r395837, trunk/res/res_pjsip_pubsub.exports.in
    team/kmoore/event_system_strip/res/res_pjsip_refer.c
      - copied unchanged from r395837, trunk/res/res_pjsip_refer.c
    team/kmoore/event_system_strip/res/res_pjsip_registrar.c
      - copied unchanged from r395837, trunk/res/res_pjsip_registrar.c
    team/kmoore/event_system_strip/res/res_pjsip_registrar_expire.c
      - copied unchanged from r395837, trunk/res/res_pjsip_registrar_expire.c
    team/kmoore/event_system_strip/res/res_pjsip_rfc3326.c
      - copied unchanged from r395837, trunk/res/res_pjsip_rfc3326.c
    team/kmoore/event_system_strip/res/res_pjsip_sdp_rtp.c
      - copied unchanged from r395837, trunk/res/res_pjsip_sdp_rtp.c
    team/kmoore/event_system_strip/res/res_pjsip_session.c
      - copied unchanged from r395837, trunk/res/res_pjsip_session.c
    team/kmoore/event_system_strip/res/res_pjsip_session.exports.in
      - copied unchanged from r395837, trunk/res/res_pjsip_session.exports.in
    team/kmoore/event_system_strip/res/res_pjsip_t38.c
      - copied unchanged from r395837, trunk/res/res_pjsip_t38.c
    team/kmoore/event_system_strip/res/res_pjsip_transport_websocket.c
      - copied unchanged from r395837, trunk/res/res_pjsip_transport_websocket.c
Removed:
    team/kmoore/event_system_strip/channels/chan_gulp.c
    team/kmoore/event_system_strip/configs/res_sip.conf.sample
    team/kmoore/event_system_strip/include/asterisk/res_sip.h
    team/kmoore/event_system_strip/include/asterisk/res_sip_exten_state.h
    team/kmoore/event_system_strip/include/asterisk/res_sip_pubsub.h
    team/kmoore/event_system_strip/include/asterisk/res_sip_session.h
    team/kmoore/event_system_strip/res/res_sip/
    team/kmoore/event_system_strip/res/res_sip.c
    team/kmoore/event_system_strip/res/res_sip.exports.in
    team/kmoore/event_system_strip/res/res_sip_acl.c
    team/kmoore/event_system_strip/res/res_sip_authenticator_digest.c
    team/kmoore/event_system_strip/res/res_sip_caller_id.c
    team/kmoore/event_system_strip/res/res_sip_diversion.c
    team/kmoore/event_system_strip/res/res_sip_dtmf_info.c
    team/kmoore/event_system_strip/res/res_sip_endpoint_identifier_anonymous.c
    team/kmoore/event_system_strip/res/res_sip_endpoint_identifier_constant.c
    team/kmoore/event_system_strip/res/res_sip_endpoint_identifier_ip.c
    team/kmoore/event_system_strip/res/res_sip_endpoint_identifier_user.c
    team/kmoore/event_system_strip/res/res_sip_exten_state.c
    team/kmoore/event_system_strip/res/res_sip_exten_state.exports.in
    team/kmoore/event_system_strip/res/res_sip_logger.c
    team/kmoore/event_system_strip/res/res_sip_messaging.c
    team/kmoore/event_system_strip/res/res_sip_mwi.c
    team/kmoore/event_system_strip/res/res_sip_nat.c
    team/kmoore/event_system_strip/res/res_sip_notify.c
    team/kmoore/event_system_strip/res/res_sip_one_touch_record_info.c
    team/kmoore/event_system_strip/res/res_sip_outbound_authenticator_digest.c
    team/kmoore/event_system_strip/res/res_sip_outbound_registration.c
    team/kmoore/event_system_strip/res/res_sip_pidf.c
    team/kmoore/event_system_strip/res/res_sip_pubsub.c
    team/kmoore/event_system_strip/res/res_sip_pubsub.exports.in
    team/kmoore/event_system_strip/res/res_sip_refer.c
    team/kmoore/event_system_strip/res/res_sip_registrar.c
    team/kmoore/event_system_strip/res/res_sip_registrar_expire.c
    team/kmoore/event_system_strip/res/res_sip_rfc3326.c
    team/kmoore/event_system_strip/res/res_sip_sdp_rtp.c
    team/kmoore/event_system_strip/res/res_sip_session.c
    team/kmoore/event_system_strip/res/res_sip_session.exports.in
    team/kmoore/event_system_strip/res/res_sip_transport_websocket.c
Modified:
    team/kmoore/event_system_strip/   (props changed)
    team/kmoore/event_system_strip/include/asterisk/mixmonitor.h   (props changed)
    team/kmoore/event_system_strip/main/abstract_jb.c
    team/kmoore/event_system_strip/main/loader.c
    team/kmoore/event_system_strip/main/mixmonitor.c   (contents, props changed)
    team/kmoore/event_system_strip/res/Makefile
    team/kmoore/event_system_strip/res/parking/parking_devicestate.c   (props changed)
    team/kmoore/event_system_strip/res/res_pktccops.c
    team/kmoore/event_system_strip/tests/test_cel.c

Propchange: team/kmoore/event_system_strip/
------------------------------------------------------------------------------
    automerge = *

Propchange: team/kmoore/event_system_strip/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Wed Jul 31 08:10:29 2013
@@ -1,1 +1,1 @@
-/trunk:1-395669
+/trunk:1-395849

Propchange: team/kmoore/event_system_strip/include/asterisk/mixmonitor.h
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Wed Jul 31 08:10:29 2013
@@ -1,1 +1,1 @@
-"Author Date Id Revision"
+Author Date Id Revision

Modified: team/kmoore/event_system_strip/main/abstract_jb.c
URL: http://svnview.digium.com/svn/asterisk/team/kmoore/event_system_strip/main/abstract_jb.c?view=diff&rev=395850&r1=395849&r2=395850
==============================================================================
--- team/kmoore/event_system_strip/main/abstract_jb.c (original)
+++ team/kmoore/event_system_strip/main/abstract_jb.c Wed Jul 31 08:10:29 2013
@@ -409,7 +409,6 @@
 	struct ast_jb_conf *jbconf = &jb->conf;
 	const struct ast_jb_impl *jbimpl = jb->impl;
 	void *jbobj;
-	struct ast_channel *bridged;
 	long now;
 	char logfile_pathname[20 + AST_JB_IMPL_NAME_SIZE + 2*AST_CHANNEL_NAME + 1];
 	char name1[AST_CHANNEL_NAME], name2[AST_CHANNEL_NAME], *tmp;
@@ -442,14 +441,15 @@
 
 	/* Create a frame log file */
 	if (ast_test_flag(jbconf, AST_JB_LOG)) {
+		RAII_VAR(struct ast_channel *, bridged, ast_channel_bridge_peer(chan), ast_channel_cleanup);
 		char safe_logfile[30] = "/tmp/logfile-XXXXXX";
 		int safe_fd;
+
 		snprintf(name2, sizeof(name2), "%s", ast_channel_name(chan));
 		if ((tmp = strchr(name2, '/'))) {
 			*tmp = '#';
 		}
 
-		bridged = ast_bridged_channel(chan);
 		/* We should always have bridged chan if a jitterbuffer is in use */
 		ast_assert(bridged != NULL);
 

Modified: team/kmoore/event_system_strip/main/loader.c
URL: http://svnview.digium.com/svn/asterisk/team/kmoore/event_system_strip/main/loader.c?view=diff&rev=395850&r1=395849&r2=395850
==============================================================================
--- team/kmoore/event_system_strip/main/loader.c (original)
+++ team/kmoore/event_system_strip/main/loader.c Wed Jul 31 08:10:29 2013
@@ -50,7 +50,7 @@
 #include "asterisk/enum.h"
 #include "asterisk/http.h"
 #include "asterisk/lock.h"
-#include "asterisk/features.h"
+#include "asterisk/features_config.h"
 #include "asterisk/dsp.h"
 #include "asterisk/udptl.h"
 #include "asterisk/heap.h"
@@ -313,7 +313,7 @@
 	{ "manager",	reload_manager },
 	{ "http",	ast_http_reload },
 	{ "logger",	logger_reload },
-	{ "features",	ast_features_reload },
+	{ "features",	ast_features_config_reload },
 	{ "dsp",	ast_dsp_reload},
 	{ "udptl",	ast_udptl_reload },
 	{ "indications", ast_indications_reload },

Modified: team/kmoore/event_system_strip/main/mixmonitor.c
URL: http://svnview.digium.com/svn/asterisk/team/kmoore/event_system_strip/main/mixmonitor.c?view=diff&rev=395850&r1=395849&r2=395850
==============================================================================
--- team/kmoore/event_system_strip/main/mixmonitor.c (original)
+++ team/kmoore/event_system_strip/main/mixmonitor.c Wed Jul 31 08:10:29 2013
@@ -29,7 +29,7 @@
 
 #include "asterisk.h"
 
-ASTERISK_FILE_VERSION(__FILE__, "$Revision: 390830 $")
+ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
 #include "asterisk/lock.h"
 #include "asterisk/logger.h"

Propchange: team/kmoore/event_system_strip/main/mixmonitor.c
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Wed Jul 31 08:10:29 2013
@@ -1,1 +1,1 @@
-"Author Date Id Revision"
+Author Date Id Revision

Modified: team/kmoore/event_system_strip/res/Makefile
URL: http://svnview.digium.com/svn/asterisk/team/kmoore/event_system_strip/res/Makefile?view=diff&rev=395850&r1=395849&r2=395850
==============================================================================
--- team/kmoore/event_system_strip/res/Makefile (original)
+++ team/kmoore/event_system_strip/res/Makefile Wed Jul 31 08:10:29 2013
@@ -43,8 +43,8 @@
 $(if $(filter res_ael_share,$(EMBEDDED_MODS)),modules.link,res_ael_share.so): ael/ael_lex.o ael/ael.tab.o ael/pval.o
 ael/ael_lex.o ael/ael.tab.o ael/pval.o: _ASTCFLAGS+=$(call MOD_ASTCFLAGS,res_ael_share)
 
-$(if $(filter res_sip,$(EMBEDDED_MODS)),modules.link,res_sip.so): $(subst .c,.o,$(wildcard res_sip/*.c))
-$(subst .c,.o,$(wildcard res_sip/*.c)): _ASTCFLAGS+=$(call MOD_ASTCFLAGS,res_sip)
+$(if $(filter res_pjsip,$(EMBEDDED_MODS)),modules.link,res_pjsip.so): $(subst .c,.o,$(wildcard res_pjsip/*.c))
+$(subst .c,.o,$(wildcard res_pjsip/*.c)): _ASTCFLAGS+=$(call MOD_ASTCFLAGS,res_pjsip)
 
 $(if $(filter res_stasis,$(EMBEDDED_MODS)),modules.link,res_stasis.so): $(subst .c,.o,$(wildcard stasis/*.c))
 $(subst .c,.o,$(wildcard stasis/*.c)): _ASTCFLAGS+=$(call MOD_ASTCFLAGS,res_stasis)
@@ -74,7 +74,7 @@
 
 clean::
 	rm -f snmp/*.[oi] ael/*.[oi] ais/*.[oi] ari/*.[oi]
-	rm -f res_sip/*.[oi] stasis/*.[oi]
+	rm -f res_pjsip/*.[oi] stasis/*.[oi]
 	rm -f parking/*.o parking/*.i
 
 $(if $(filter res_parking,$(EMBEDDED_MODS)),modules.link,res_parking.so): $(subst .c,.o,$(wildcard parking/*.c))

Propchange: team/kmoore/event_system_strip/res/parking/parking_devicestate.c
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Wed Jul 31 08:10:29 2013
@@ -1,1 +1,1 @@
-"Author Date Id Revision"
+Author Date Id Revision

Propchange: team/kmoore/event_system_strip/res/res_pjsip/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Wed Jul 31 08:10:29 2013
@@ -1,0 +1,2 @@
+*.i
+*.o

Modified: team/kmoore/event_system_strip/res/res_pktccops.c
URL: http://svnview.digium.com/svn/asterisk/team/kmoore/event_system_strip/res/res_pktccops.c?view=diff&rev=395850&r1=395849&r2=395850
==============================================================================
--- team/kmoore/event_system_strip/res/res_pktccops.c (original)
+++ team/kmoore/event_system_strip/res/res_pktccops.c Wed Jul 31 08:10:29 2013
@@ -1347,7 +1347,7 @@
 	if (a->argc < 9)
 		return CLI_SHOWUSAGE;
 
-	if (!strncmp(a->argv[2], "null", sizeof(a->argv[2]))) {
+	if (!strcmp(a->argv[2], "null")) {
 		cmts = NULL;
 	} else {
 		AST_LIST_LOCK(&cmts_list);

Modified: team/kmoore/event_system_strip/tests/test_cel.c
URL: http://svnview.digium.com/svn/asterisk/team/kmoore/event_system_strip/tests/test_cel.c?view=diff&rev=395850&r1=395849&r2=395850
==============================================================================
--- team/kmoore/event_system_strip/tests/test_cel.c (original)
+++ team/kmoore/event_system_strip/tests/test_cel.c Wed Jul 31 08:10:29 2013
@@ -61,6 +61,18 @@
 /*! \brief The CEL config used for CEL unit tests */
 static struct ast_cel_general_config *cel_test_config;
 
+/*! \brief Lock used for synchronizing test execution stages with received events */
+ast_mutex_t mid_test_sync_lock;
+
+/*! \brief Lock used with sync_out for checking the end of test execution */
+ast_mutex_t sync_lock;
+
+/*! \brief Condition used for checking the end of test execution */
+ast_cond_t sync_out;
+
+/*! \brief Flag used to trigger a mid-test synchronization, access controlled by mid_test_sync_lock */
+int do_mid_test_sync = 0;
+
 /*! \brief A channel technology used for the unit tests */
 static struct ast_channel_tech test_cel_chan_tech = {
 	.type = CHANNEL_TECH_NAME,
@@ -96,6 +108,7 @@
 #define CONF_EXIT(channel, bridge) do { \
 	ast_test_validate(test, 0 == ast_bridge_depart(channel)); \
 	CONF_EXIT_EVENT(channel, bridge); \
+	mid_test_sync(); \
 	} while (0)
 
 #define CONF_EXIT_EVENT(channel, bridge) do { \
@@ -227,6 +240,8 @@
 	APPEND_EVENT(channel, AST_CEL_HANGUP, NULL, extra, NULL); \
 	} while (0)
 
+static void mid_test_sync(void);
+
 static int append_expected_event(
 	struct ast_channel *chan,
 	enum ast_cel_event_type type,
@@ -597,11 +612,8 @@
 	BRIDGE_TO_CONF(chan_alice, chan_bob, chan_charlie, bridge);
 
 	CONF_EXIT(chan_alice, bridge);
-	do_sleep();
 	CONF_EXIT(chan_bob, bridge);
-	do_sleep();
 	CONF_EXIT(chan_charlie, bridge);
-	do_sleep();
 
 	HANGUP_CHANNEL(chan_alice, AST_CAUSE_NORMAL, "");
 	HANGUP_CHANNEL(chan_bob, AST_CAUSE_NORMAL, "");
@@ -1072,11 +1084,8 @@
 	CONF_ENTER_EVENT(chan_alice, bridge);
 
 	CONF_EXIT(chan_alice, bridge);
-	do_sleep();
 	CONF_EXIT(chan_bob, bridge);
-	do_sleep();
 	CONF_EXIT(chan_charlie, bridge);
-	do_sleep();
 	CONF_EXIT(chan_david, bridge);
 
 	HANGUP_CHANNEL(chan_alice, AST_CAUSE_NORMAL, "ANSWER");
@@ -1212,10 +1221,8 @@
 
 	do_sleep();
 	CONF_EXIT(chan_bob, bridge2);
-	do_sleep();
 	CONF_EXIT(chan_charlie, bridge2);
 
-	do_sleep();
 	HANGUP_CHANNEL(chan_alice, AST_CAUSE_NORMAL, "");
 	do_sleep();
 	HANGUP_CHANNEL(chan_bob, AST_CAUSE_NORMAL, "");
@@ -1300,10 +1307,8 @@
 
 	do_sleep();
 	CONF_EXIT(chan_bob, bridge1);
-	do_sleep();
 	CONF_EXIT(chan_charlie, bridge1);
 
-	do_sleep();
 	HANGUP_CHANNEL(chan_alice, AST_CAUSE_NORMAL, "");
 	do_sleep();
 	HANGUP_CHANNEL(chan_bob, AST_CAUSE_NORMAL, "");
@@ -1411,10 +1416,8 @@
 
 	do_sleep();
 	CONF_EXIT(chan_bob, bridge1);
-	do_sleep();
 	CONF_EXIT(chan_charlie, bridge2);
 
-	do_sleep();
 	HANGUP_CHANNEL(chan_alice, AST_CAUSE_NORMAL, "");
 	do_sleep();
 	HANGUP_CHANNEL(chan_bob, AST_CAUSE_NORMAL, "");
@@ -1558,6 +1561,29 @@
 	return event_dup;
 }
 
+static void mid_test_sync(void)
+{
+	ast_mutex_lock(&mid_test_sync_lock);
+	if (ao2_container_count(cel_expected_events) <= ao2_container_count(cel_received_events)) {
+		ast_mutex_unlock(&mid_test_sync_lock);
+		return;
+	}
+
+	do_mid_test_sync = 1;
+	ast_mutex_unlock(&mid_test_sync_lock);
+
+	{
+		struct timeval start = ast_tvnow();
+		struct timespec end = {
+			.tv_sec = start.tv_sec + 15,
+			.tv_nsec = start.tv_usec * 1000
+		};
+
+		SCOPED_MUTEX(lock, &sync_lock);
+		ast_cond_timedwait(&sync_out, &sync_lock, &end);
+	}
+}
+
 static int append_event(struct ast_event *ev)
 {
 	RAII_VAR(struct ast_event *, ao2_ev, NULL, ao2_cleanup);
@@ -1613,13 +1639,12 @@
 	return append_expected_event_snapshot(snapshot, type, userdefevname, extra, peer);
 }
 
-ast_mutex_t sync_lock;
-ast_cond_t sync_out;
-
 static void test_sub(const struct ast_event *event, void *data)
 {
 	struct ast_event *event_dup = ao2_dup_event(event);
 	const char *sync_tag;
+	SCOPED_MUTEX(mid_test_lock, &mid_test_sync_lock);
+
 	if (!event_dup) {
 		return;
 	}
@@ -1633,8 +1658,21 @@
 			return;
 		}
 	}
+
 	/* save the event for later processing */
 	ao2_link(cel_received_events, event_dup);
+
+	if (do_mid_test_sync) {
+		int expected = ao2_container_count(cel_expected_events);
+		int received = ao2_container_count(cel_received_events);
+		if (expected <= received) {
+			{
+			SCOPED_MUTEX(lock, &sync_lock);
+			ast_cond_signal(&sync_out);
+			do_mid_test_sync = 0;
+			}
+		}
+	}
 }
 
 /*!
@@ -1646,6 +1684,7 @@
 	ast_assert(cel_received_events == NULL);
 	ast_assert(cel_expected_events == NULL);
 
+	ast_mutex_init(&mid_test_sync_lock);
 	ast_mutex_init(&sync_lock);
 	ast_cond_init(&sync_out, NULL);
 
@@ -1866,7 +1905,7 @@
 	} else {
 		struct timeval start = ast_tvnow();
 		struct timespec end = {
-			.tv_sec = start.tv_sec + 30,
+			.tv_sec = start.tv_sec + 15,
 			.tv_nsec = start.tv_usec * 1000
 		};
 
@@ -1892,6 +1931,7 @@
 
 	/* clean up the locks */
 	ast_mutex_destroy(&sync_lock);
+	ast_mutex_destroy(&mid_test_sync_lock);
 	ast_cond_destroy(&sync_out);
 	return 0;
 }




More information about the asterisk-commits mailing list