aboutsummaryrefslogtreecommitdiff
path: root/backends/text-to-speech/linux/linux-text-to-speech.cpp
diff options
context:
space:
mode:
authorJaromir Wysoglad2019-07-18 23:53:52 +0200
committerFilippos Karapetis2019-09-01 22:47:55 +0300
commitb5d5576f90c177c54170a4e68b251c2fd5219260 (patch)
treead3dbb3d8085cfa02ebb50920264cb2268b9efb4 /backends/text-to-speech/linux/linux-text-to-speech.cpp
parent788b15652db9c5d062520c3202d30c827fd6fe21 (diff)
downloadscummvm-rg350-b5d5576f90c177c54170a4e68b251c2fd5219260.tar.gz
scummvm-rg350-b5d5576f90c177c54170a4e68b251c2fd5219260.tar.bz2
scummvm-rg350-b5d5576f90c177c54170a4e68b251c2fd5219260.zip
TTS: Add check to getVoice, fix typo.
Check if _availableVoices isn't empty. Replace availaible with available
Diffstat (limited to 'backends/text-to-speech/linux/linux-text-to-speech.cpp')
-rw-r--r--backends/text-to-speech/linux/linux-text-to-speech.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/backends/text-to-speech/linux/linux-text-to-speech.cpp b/backends/text-to-speech/linux/linux-text-to-speech.cpp
index 4b01b4478b..9abe805767 100644
--- a/backends/text-to-speech/linux/linux-text-to-speech.cpp
+++ b/backends/text-to-speech/linux/linux-text-to-speech.cpp
@@ -184,8 +184,8 @@ bool LinuxTextToSpeechManager::isReady() {
void LinuxTextToSpeechManager::setVoice(unsigned index) {
if (_speechState == BROKEN)
return;
- assert(index < _ttsState->_availaibleVoices.size());
- Common::TTSVoice voice = _ttsState->_availaibleVoices[index];
+ assert(index < _ttsState->_availableVoices.size());
+ Common::TTSVoice voice = _ttsState->_availableVoices[index];
spd_set_voice_type(_connection, *(SPDVoiceType *)(voice.getData()));
_ttsState->_activeVoice = index;
}
@@ -230,7 +230,7 @@ void LinuxTextToSpeechManager::createVoice(int typeNumber, Common::TTSVoice::Gen
SPDVoiceType *type = (SPDVoiceType *) malloc(sizeof(SPDVoiceType));
*type = static_cast<SPDVoiceType>(typeNumber);
Common::TTSVoice voice(gender, age, (void *) type, description);
- _ttsState->_availaibleVoices.push_back(voice);
+ _ttsState->_availableVoices.push_back(voice);
}
void LinuxTextToSpeechManager::updateVoices() {