Fix rate setting without libsonic (#1524)

Move a code that should be shared outside HAVE_SONIC_H ifdef.

That also simplifies prosody SSML tests (made by @sthibaul) by removing
unnecessary cases.

Ref: #1512 #1368
This commit is contained in:
Alexander Epaneshnikov
2022-11-15 19:36:15 +03:00
committed by GitHub
2 changed files with 7 additions and 8 deletions
+2 -3
View File
@@ -155,11 +155,10 @@ void SetSpeed(int control)
if (control == 2)
wpm = embedded_value[EMBED_S2];
#if HAVE_SONIC_H
int wpm_value;
speed.min_pause = 5;
wpm_value = wpm;
#if HAVE_SONIC_H
int wpm_value = wpm;
if (voice->speed_percent > 0)
wpm = (wpm * voice->speed_percent)/100;