[Freeswitch-svn] [commit] r8846 - freeswitch/trunk/src/mod/applications/mod_rss

Freeswitch SVN mikej at freeswitch.org
Wed Jun 25 18:09:34 EDT 2008


Author: mikej
Date: Wed Jun 25 18:09:33 2008
New Revision: 8846

Modified:
   freeswitch/trunk/src/mod/applications/mod_rss/mod_rss.c

Log:
use the session interval

Modified: freeswitch/trunk/src/mod/applications/mod_rss/mod_rss.c
==============================================================================
--- freeswitch/trunk/src/mod/applications/mod_rss/mod_rss.c	(original)
+++ freeswitch/trunk/src/mod/applications/mod_rss/mod_rss.c	Wed Jun 25 18:09:33 2008
@@ -170,7 +170,6 @@
 	switch_speech_handle_t sh;
 	switch_speech_flag_t flags = SWITCH_SPEECH_FLAG_NONE;
 	switch_core_thread_session_t thread_session;
-	uint32_t rate, interval = 20;
 	switch_timer_t timer = { 0 }, *timerp = NULL;
 	uint32_t last;
 	char *mydata = NULL;
@@ -186,6 +185,8 @@
 	switch_input_args_t args = { 0 };
 	const char *vcf = NULL;
 	char *chanvars = switch_channel_build_param_string(channel, NULL, NULL);
+	switch_codec_t *read_codec = switch_core_session_get_read_codec(session);
+	uint32_t rate, interval = read_codec->implementation->microseconds_per_frame / 1000;
 
 	if ((vcf = switch_channel_get_variable(channel, "rss_alt_config"))) {
 		cf = vcf;



More information about the Freeswitch-svn mailing list