Skip to content

Commit

Permalink
mpg123: Don't treat MPG123_NEW_FORMAT as error
Browse files Browse the repository at this point in the history
Seeking a few of my MP3 files could cause error messages like below.
In fact MPG123_NEW_FORMAT is no real error and can be ignored.

ERROR ../src/mpg123/mpg123.cc:368 [play]:
mpg123 error in file:///home/thomas/Sample.mp3: No error... (code 0)

See also: https://mpg123.de/api/group__mpg123__error.shtml
  • Loading branch information
radioactiveman committed Jan 21, 2024
1 parent e8406b3 commit bd6455f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/mpg123/mpg123.cc
Original file line number Diff line number Diff line change
Expand Up @@ -361,6 +361,9 @@ bool MPG123Plugin::play(const char * filename, VFSFile & file)
if (ret == MPG123_DONE || ret == MPG123_ERR_READER)
break;

if (ret == MPG123_NEW_FORMAT)
continue;

if (ret < 0)
{
// log only the first error
Expand Down

0 comments on commit bd6455f

Please sign in to comment.