clean up speak code

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5670 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale
2007-08-28 17:06:20 +00:00
parent 352cc95813
commit 160edc558d
8 changed files with 17 additions and 23 deletions
+2 -3
View File
@@ -123,7 +123,6 @@ void CoreSession::setDTMFCallback(void *cbfunc, char *funcargs) {
int CoreSession::speak(char *text)
{
switch_status_t status;
switch_codec_t *codec;
sanity_check(-1);
@@ -142,9 +141,9 @@ int CoreSession::speak(char *text)
return SWITCH_STATUS_FALSE;
}
codec = switch_core_session_get_read_codec(session);
begin_allow_threads();
status = switch_ivr_speak_text(session, tts_name, voice_name, codec->implementation->samples_per_second, text, ap);
status = switch_ivr_speak_text(session, tts_name, voice_name, text, ap);
end_allow_threads();
return status == SWITCH_STATUS_SUCCESS ? 1 : 0;
}