cleanup: Change severity of fread short-read warning

Many sound files don't have a full frame's worth of data at EOF, so the
warning messages were a bit too noisy. So we demote them to debug
messages.

Change-Id: I6b617467d687658adca39170a81797a11cc766f6
This commit is contained in:
Sean Bright
2017-05-02 12:34:24 -04:00
parent dc948163ca
commit 675e058e77
15 changed files with 45 additions and 45 deletions

View File

@@ -424,9 +424,9 @@ static struct ast_frame *wav_read(struct ast_filestream *s, int *whennext)
if ((res = fread(msdata, 1, MSGSM_FRAME_SIZE, s->f)) != MSGSM_FRAME_SIZE) {
if (feof(s->f)) {
if (res) {
ast_log(LOG_WARNING, "Incomplete frame data at end of %s file "
"(expected %d bytes, read %d)\n",
ast_format_get_name(s->fr.subclass.format), MSGSM_FRAME_SIZE, res);
ast_debug(3, "Incomplete frame data at end of %s file "
"(expected %d bytes, read %d)\n",
ast_format_get_name(s->fr.subclass.format), MSGSM_FRAME_SIZE, res);
}
} else {
ast_log(LOG_ERROR, "Error while reading %s file: %s\n",