diff options
author | Michael Sevakis <jethead71@rockbox.org> | 2012-05-24 20:59:05 -0400 |
---|---|---|
committer | Michael Sevakis <jethead71@rockbox.org> | 2012-05-24 20:59:05 -0400 |
commit | 652b39b9e1ee324825e1a7d6b6c7feb3f4d9e880 (patch) | |
tree | 44cf4ea17a323a1ce1de2f8846bed5a1d47675f5 | |
parent | 4b97437c23b18cb31e69e623b0dc726c77ef4cd3 (diff) |
More snafu fix. Need a couple more patchups for now.
Must restore talk buffer explicitly when not taking it and promote
the buffer state.
Change-Id: Ia0341ede05837e6e94885a9ad62460c415ec6f00
-rw-r--r-- | apps/playback.c | 3 | ||||
-rw-r--r-- | apps/talk.c | 1 |
2 files changed, 2 insertions, 2 deletions
diff --git a/apps/playback.c b/apps/playback.c index 21cc017aaf..9671f30100 100644 --- a/apps/playback.c +++ b/apps/playback.c @@ -3624,8 +3624,7 @@ unsigned char * audio_get_buffer(bool talk_buf, size_t *buffer_size) if (buffer_state == AUDIOBUF_STATE_INITIALIZED) buffering_reset(NULL, 0); /* mark buffer invalid */ - if (talk_buf || buffer_state == AUDIOBUF_STATE_TRASHED - || !talk_voice_required()) + if (talk_buf || !talk_voice_required()) { logf("get buffer: talk, audio"); /* Ok to use everything from audiobuf - voice is loaded, diff --git a/apps/talk.c b/apps/talk.c index 3634ecfe08..675cfa0966 100644 --- a/apps/talk.c +++ b/apps/talk.c @@ -627,6 +627,7 @@ static bool restore_state(void) size_t size; audio_restore_playback(AUDIO_WANT_VOICE); voicebuf = audio_get_buffer(true, &size); + audio_get_buffer(false, &size); } return !!voicebuf; |