Fix usage of calloc in espeak_ng_CompileIntonation. [clang scan-build]

This commit is contained in:
Reece H. Dunn
2016-01-07 20:28:11 +00:00
parent 209bbe3369
commit c675787587
+1 -1
View File
@@ -2867,7 +2867,7 @@ espeak_ng_STATUS espeak_ng_CompileIntonation(FILE *log, espeak_ng_ERROR_CONTEXT
rewind(f_in);
linenum = 1;
tune_data = (TUNE *)calloc(sizeof(TUNE), n_tune_names);
tune_data = (n_tune_names == 0) ? NULL : (TUNE *)calloc(n_tune_names, sizeof(TUNE));
if (tune_data == NULL) {
fclose(f_in);
fclose(f_errors);