[Freeswitch-svn] [commit] r2773 - freeswitch/trunk/src

Freeswitch SVN anthm at freeswitch.org
Thu Sep 21 15:51:40 EDT 2006


Author: anthm
Date: Thu Sep 21 15:51:39 2006
New Revision: 2773

Modified:
   freeswitch/trunk/src/switch_rtp.c

Log:
fixrtp

Modified: freeswitch/trunk/src/switch_rtp.c
==============================================================================
--- freeswitch/trunk/src/switch_rtp.c	(original)
+++ freeswitch/trunk/src/switch_rtp.c	Thu Sep 21 15:51:39 2006
@@ -475,15 +475,15 @@
 		}
 	}
 
-	if (timer_name) {
+	if (!switch_strlen_zero(timer_name)) {
 		switch_set_flag_locked(rtp_session, SWITCH_RTP_FLAG_USE_TIMER);
 	}
 
-	if (switch_test_flag(rtp_session, SWITCH_RTP_FLAG_USE_TIMER) && !timer_name) {
+	if (switch_test_flag(rtp_session, SWITCH_RTP_FLAG_USE_TIMER) && switch_strlen_zero(timer_name)) {
 		timer_name = "soft";
 	}
 
-	if (timer_name) {
+	if (!switch_strlen_zero(timer_name)) {
 		if (switch_core_timer_init(&rtp_session->timer, timer_name, ms_per_packet / 1000, packet_size, rtp_session->pool) == SWITCH_STATUS_SUCCESS) {
 			switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Starting timer [%s] %d bytes per %dms\n", timer_name, packet_size, ms_per_packet);
 		} else {



More information about the Freeswitch-svn mailing list