mirror of
https://github.com/rhasspy/espeak-ng.git
synced 2026-12-06 08:40:54 +00:00
Check fseek calls in CloseWavFile(espeak-ng.c). [Coverity]
This commit is contained in:
+4
-4
@@ -233,11 +233,11 @@ static void CloseWavFile()
|
|||||||
fflush(f_wavfile);
|
fflush(f_wavfile);
|
||||||
pos = ftell(f_wavfile);
|
pos = ftell(f_wavfile);
|
||||||
|
|
||||||
fseek(f_wavfile, 4, SEEK_SET);
|
if (fseek(f_wavfile, 4, SEEK_SET) != -1)
|
||||||
Write4Bytes(f_wavfile, pos - 8);
|
Write4Bytes(f_wavfile, pos - 8);
|
||||||
|
|
||||||
fseek(f_wavfile, 40, SEEK_SET);
|
if (fseek(f_wavfile, 40, SEEK_SET) != -1)
|
||||||
Write4Bytes(f_wavfile, pos - 44);
|
Write4Bytes(f_wavfile, pos - 44);
|
||||||
|
|
||||||
fclose(f_wavfile);
|
fclose(f_wavfile);
|
||||||
f_wavfile = NULL;
|
f_wavfile = NULL;
|
||||||
|
|||||||
Reference in New Issue
Block a user