[Freeswitch-svn] [commit] r2811 - in freeswitch/branches/tholo: . src/mod/endpoints/mod_sofia src/mod/languages/mod_mono

Freeswitch SVN tholo at freeswitch.org
Sat Sep 23 18:44:00 EDT 2006


Author: tholo
Date: Sat Sep 23 18:44:00 2006
New Revision: 2811

Modified:
   freeswitch/branches/tholo/   (props changed)
   freeswitch/branches/tholo/src/mod/endpoints/mod_sofia/mod_sofia.c
   freeswitch/branches/tholo/src/mod/languages/mod_mono/mod_mono.c

Log:
Merge changes from trunk

Modified: freeswitch/branches/tholo/src/mod/endpoints/mod_sofia/mod_sofia.c
==============================================================================
--- freeswitch/branches/tholo/src/mod/endpoints/mod_sofia/mod_sofia.c	(original)
+++ freeswitch/branches/tholo/src/mod/endpoints/mod_sofia/mod_sofia.c	Sat Sep 23 18:44:00 2006
@@ -140,7 +140,6 @@
 	switch_codec_t read_codec;
 	switch_codec_t write_codec;
 	uint32_t codec_index;
-	uint32_t codec_rate;
 	uint32_t codec_ms;
 	switch_caller_profile_t *caller_profile;
 	int32_t timestamp_send;
@@ -690,11 +689,11 @@
 			return SWITCH_STATUS_FALSE;
 		} else {
 			int ms;
-			tech_pvt->read_frame.rate = tech_pvt->codec_rate;
+			tech_pvt->read_frame.rate = tech_pvt->rm_rate;
 			ms = tech_pvt->write_codec.implementation->microseconds_per_frame / 1000;
 			switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "Set Codec %s %s/%d %d ms\n",
 							  switch_channel_get_name(channel),
-							  tech_pvt->codecs[tech_pvt->codec_index]->iananame, tech_pvt->codec_rate, tech_pvt->codec_ms);
+							  tech_pvt->codecs[tech_pvt->codec_index]->iananame, tech_pvt->rm_rate, tech_pvt->codec_ms);
 			tech_pvt->read_frame.codec = &tech_pvt->read_codec;
 				
 			switch_core_session_set_read_codec(tech_pvt->session, &tech_pvt->read_codec);

Modified: freeswitch/branches/tholo/src/mod/languages/mod_mono/mod_mono.c
==============================================================================
--- freeswitch/branches/tholo/src/mod/languages/mod_mono/mod_mono.c	(original)
+++ freeswitch/branches/tholo/src/mod/languages/mod_mono/mod_mono.c	Sat Sep 23 18:44:00 2006
@@ -96,12 +96,12 @@
 	char *assembly_dir  = (char *) switch_core_alloc(mono_pool, assembly_dir_len);
 	char *assembly_file = (char *) switch_core_alloc(mono_pool, assembly_file_len);
 
-	apr_finfo_t *finfo = (apr_finfo_t *) switch_core_alloc(mono_pool, sizeof(*finfo));
+	apr_finfo_t *assembly_finfo = (apr_finfo_t *) switch_core_alloc(mono_pool, sizeof(*assembly_finfo));
 
 	snprintf(assembly_dir, assembly_dir_len, "%s/%s", SWITCH_GLOBAL_dirs.base_dir, SWITCH_MONO_LIBDIR);
 	snprintf(assembly_file, assembly_file_len, "%s/%s%s", SWITCH_GLOBAL_dirs.base_dir, SWITCH_MONO_LIBDIR, SWITCH_MONO_ASSEMBLY);
 
-	if (apr_stat(finfo, assembly_file, 0, mono_pool) != SWITCH_STATUS_SUCCESS) {
+	if (apr_stat(assembly_finfo, assembly_file, 0, mono_pool) != SWITCH_STATUS_SUCCESS) {
 		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Could not find FreeSwitch.NET assembly\n");
 		return SWITCH_STATUS_FALSE;
 	}
@@ -178,6 +178,13 @@
  */ 
 switch_status_t mod_mono_load_modules(const char *module_dir)
 {
+	apr_finfo_t *module_finfo = (apr_finfo_t *) switch_core_alloc(mono_pool, sizeof(*module_finfo));
+	
+	if (apr_stat(module_finfo, module_dir, 0, mono_pool) != SWITCH_STATUS_SUCCESS) {
+		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Could not access module dir!.\n");
+		return SWITCH_STATUS_FALSE;
+	}
+	
 	apr_dir_t *module_dir_handle;
 	char *file;
 	size_t len;



More information about the Freeswitch-svn mailing list