summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--apps/talk.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/apps/talk.c b/apps/talk.c
index f32e1b6e0b..a22aac02b7 100644
--- a/apps/talk.c
+++ b/apps/talk.c
@@ -677,9 +677,7 @@ void talk_init(void)
677 677
678 voicefile_size = filesize(filehandle); 678 voicefile_size = filesize(filehandle);
679 679
680#if CONFIG_CODEC == SWCODEC
681 audio_get_buffer(false, NULL); /* Must tell audio to reinitialize */ 680 audio_get_buffer(false, NULL); /* Must tell audio to reinitialize */
682#endif
683 reset_state(); /* use this for most of our inits */ 681 reset_state(); /* use this for most of our inits */
684 682
685#ifdef TALK_PARTIAL_LOAD 683#ifdef TALK_PARTIAL_LOAD
@@ -744,10 +742,10 @@ size_t talkbuf_init(char *bufstart)
744{ 742{
745 bool changed = voicebuf != bufstart; 743 bool changed = voicebuf != bufstart;
746 744
747 if (bufstart)
748 voicebuf = bufstart;
749 if (changed) /* must reload voice file */ 745 if (changed) /* must reload voice file */
750 reset_state(); 746 reset_state();
747 if (bufstart)
748 voicebuf = bufstart;
751 749
752 return voicefile_size; 750 return voicefile_size;
753} 751}