mirror of
https://github.com/clangen/musikcube.git
synced 2024-12-27 21:14:08 +00:00
Don't show EOF errors by default when decoding, as they're usually nothing to worry about and pollute the log.
This commit is contained in:
parent
16af22a7d1
commit
3b95b17753
@ -64,6 +64,11 @@ static std::string getAvError(int errnum) {
|
||||
}
|
||||
|
||||
static void logAvError(const std::string& method, int errnum) {
|
||||
#ifndef ENABLE_LOG_AVERROR_EOF
|
||||
if (errnum == AVERROR_EOF) {
|
||||
return; /* these are generally legit; no need to pollute the log */
|
||||
}
|
||||
#endif
|
||||
if (errnum != 0) {
|
||||
std::string err = method + "() failed: " + getAvError(errnum);
|
||||
::debug->Warning(TAG, err.c_str());
|
||||
|
Loading…
Reference in New Issue
Block a user