summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorXANTRONIX Development2022-03-07 11:56:31 -0500
committerXANTRONIX Development2022-03-07 11:56:31 -0500
commite7cc1aeb86e37cd55bb010a7ee26db39111db494 (patch)
tree249aa0024716cf8c7146240ca9f9bca96aef3c34 /src
parent64b0b6322bfe2d055346f2a5b150f4023ba447d0 (diff)
downloadxas-e7cc1aeb86e37cd55bb010a7ee26db39111db494.tar.gz
xas-e7cc1aeb86e37cd55bb010a7ee26db39111db494.tar.bz2
xas-e7cc1aeb86e37cd55bb010a7ee26db39111db494.zip
Do not fill buffers when speech output is complete
Diffstat (limited to 'src')
-rw-r--r--src/vox.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/vox.c b/src/vox.c
index 9d3d098..d98a81d 100644
--- a/src/vox.c
+++ b/src/vox.c
@@ -200,9 +200,7 @@ static ssize_t vox_fill(xas_vox *vox,
readcount;
if (vox->state != XAS_VOX_ACTIVE) {
- xas_audio_zero(vox->format, samples, 0, count);
-
- return count;
+ return 0;
}
if ((readlen = read(vox->stdout,
@@ -225,9 +223,7 @@ static ssize_t vox_fill(xas_vox *vox,
readcount);
}
- xas_audio_zero(vox->format, samples, readcount, count-readcount);
-
- return count;
+ return readcount;
error_read:
return -1;