[Freeswitch-svn] [commit] r11720 - freeswitch/trunk/src/mod/codecs/mod_dahdi_codec

FreeSWITCH SVN moy at freeswitch.org
Mon Feb 9 12:32:26 PST 2009


Author: moy
Date: Mon Feb  9 14:32:26 2009
New Revision: 11720

Log:
fixing zap device name and adding error message for a failed open in mod_dahdi_codec

Modified:
   freeswitch/trunk/src/mod/codecs/mod_dahdi_codec/mod_dahdi_codec.c

Modified: freeswitch/trunk/src/mod/codecs/mod_dahdi_codec/mod_dahdi_codec.c
==============================================================================
--- freeswitch/trunk/src/mod/codecs/mod_dahdi_codec/mod_dahdi_codec.c	(original)
+++ freeswitch/trunk/src/mod/codecs/mod_dahdi_codec/mod_dahdi_codec.c	Mon Feb  9 14:32:26 2009
@@ -345,7 +345,7 @@
 	if (!stat(transcoding_device_dahdi, &statbuf)) {
 		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "DAHDI transcoding device found.\n");
 		transcoding_device = transcoding_device_dahdi;
-		transcoder_name = transcoder_name_zap;
+		transcoder_name = transcoder_name_dahdi;
 	} else if (!stat(transcoding_device_zap, &statbuf)) {
 		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "Zap transcoding device found.\n");
 		transcoding_device = transcoding_device_zap;
@@ -357,7 +357,8 @@
 
 	fd = open(transcoding_device, O_RDWR);
 	if (fd < 0) {
-		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Failed to open %s transcoder device.\n", transcoder_name);
+		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Failed to open %s transcoder device: %s.\n", 
+				transcoder_name, strerror(errno));
 		return SWITCH_STATUS_FALSE;
 	}
 



More information about the Freeswitch-svn mailing list