FSCORE-341

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@12728 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale committed 2009-03-24 14:54:13 +00:00
1 parent 7b52ef1305
commit 523e0653ed
4 files changed
+26 -16

No files matched your search

+2 -1
View File
@@ -103,7 +103,8 @@ static switch_status_t sndfile_file_open(switch_file_handle_t *handle, const cha
context->sfinfo.channels = handle->channels;
context->sfinfo.samplerate = handle->samplerate;
if (handle->samplerate == 8000 || handle->samplerate == 16000 ||
handle->samplerate == 24000 || handle->samplerate == 32000 || handle->samplerate == 48000) {
handle->samplerate == 24000 || handle->samplerate == 32000 || handle->samplerate == 48000 ||
handle->samplerate == 11025 || handle->samplerate == 22050 || handle->samplerate == 44100) {
context->sfinfo.format |= SF_FORMAT_PCM_16;
}
+11 -8
View File
@@ -24,20 +24,23 @@ static switch_status_t lua_hanguphook(switch_core_session_t *session_hungup);
Session::~Session()
{
if (channel) {
switch_channel_set_private(channel, "CoreSession", NULL);
}
if (hangup_func_str) {
if (session) {
switch_core_event_hook_remove_state_change(session, lua_hanguphook);
if (session) {
if (!channel) {
channel = switch_core_session_get_channel(session);
}
switch_safe_free(hangup_func_str);
switch_channel_set_private(channel, "CoreSession", NULL);
switch_core_event_hook_remove_state_change(session, lua_hanguphook);
session = NULL;
channel = NULL;
}
switch_safe_free(hangup_func_str);
switch_safe_free(hangup_func_arg);
switch_safe_free(cb_function);
switch_safe_free(cb_arg);
init_vars();
}
bool Session::begin_allow_threads()