[PATCH] winemp3.acm: Ignore XING headers when parsing MP3 files

Bruno Jesus 00cpxxx at gmail.com
Tue Feb 7 09:55:53 CST 2017


Fixes https://bugs.winehq.org/show_bug.cgi?id=42361

Signed-off-by: Bruno Jesus <00cpxxx at gmail.com>
---
 dlls/winemp3.acm/mpegl3.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/dlls/winemp3.acm/mpegl3.c b/dlls/winemp3.acm/mpegl3.c
index 37993b4..28a1998 100644
--- a/dlls/winemp3.acm/mpegl3.c
+++ b/dlls/winemp3.acm/mpegl3.c
@@ -248,6 +248,13 @@ static	LRESULT	MPEG3_StreamOpen(PACMDRVSTREAMINSTANCE adsi)
         aad->convert = mp3_horse;
         aad->mh = mpg123_new(NULL,&err);
         mpg123_open_feed(aad->mh);
+
+        /* mpg123 may find a XING header in the mp3 and use that information
+         * to ask for seeks in order to read specific frames in the file.
+         * We cannot allow that since the caller application is feeding us.
+         * This fixes problems for mp3 files encoded with LAME (bug 42361)
+         */
+        mpg123_param(aad->mh, MPG123_ADD_FLAGS, MPG123_IGNORE_INFOFRAME, 0);
     }
     /* no encoding yet
     else if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_PCM &&
-- 
2.9.3




More information about the wine-patches mailing list