From: Yuxuan Shui yshui@codeweavers.com
MIDI files aren't RIFF, calling stream_skip_chunk on it is invalid. --- dlls/dmime/segment.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/dlls/dmime/segment.c b/dlls/dmime/segment.c index 82e06f4537d..b0485aaedd9 100644 --- a/dlls/dmime/segment.c +++ b/dlls/dmime/segment.c @@ -844,7 +844,9 @@ static HRESULT WINAPI segment_persist_stream_Load(IPersistStream *iface, IStream } }
- stream_skip_chunk(stream, &chunk); + if (chunk.id != mmioFOURCC('M', 'T', 'h', 'd')) + stream_skip_chunk(stream, &chunk); + if (FAILED(hr)) { WARN("Failed to load segment from stream %p, hr %#lx\n", stream, hr);