Rebase against d7eb469d5992f9901b0dd355e5e61709aed31d2b.

This commit is contained in:
Sebastian Lackner
2017-06-14 03:16:45 +02:00
parent ecdf44fe29
commit 2420bc89ed
4 changed files with 13 additions and 89 deletions

View File

@@ -1,23 +1,22 @@
From 3dfc0d56bc199c915455a83cc21085a6dd24a4bc Mon Sep 17 00:00:00 2001
From a9e9bf9a348ddd771fd405dae8dcbe9fcb42ddb3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Sun, 21 Aug 2016 02:36:47 +0200
Subject: winemp3.acm: Check input format in MPEG3_StreamOpen.
---
dlls/msacm32/tests/msacm.c | 72 ++++++++++++++++++++++++++++++++++++++++++++++
dlls/msacm32/tests/msacm.c | 71 ++++++++++++++++++++++++++++++++++++++++++++++
dlls/winemp3.acm/mpegl3.c | 15 +++++++++-
2 files changed, 86 insertions(+), 1 deletion(-)
2 files changed, 85 insertions(+), 1 deletion(-)
diff --git a/dlls/msacm32/tests/msacm.c b/dlls/msacm32/tests/msacm.c
index 0816cb0..783d155 100644
index 44a6febb662..21cc10bd45e 100644
--- a/dlls/msacm32/tests/msacm.c
+++ b/dlls/msacm32/tests/msacm.c
@@ -830,6 +830,77 @@ todo_wine
ok(rc == MMSYSERR_INVALPARAM, "failed with error 0x%x\n", rc);
@@ -1151,6 +1151,76 @@ static void test_acmFormatTagDetails(void)
ok(aftd.cbFormatSize == sizeof(MPEGLAYER3WAVEFORMAT), "got %d\n", aftd.cbFormatSize);
}
+
+void test_mp3(void)
+static void test_mp3(void)
+{
+ MPEGLAYER3WAVEFORMAT src;
+ WAVEFORMATEX dst;
@@ -90,16 +89,16 @@ index 0816cb0..783d155 100644
static struct
{
struct
@@ -997,6 +1068,7 @@ START_TEST(msacm)
driver_tests();
@@ -1319,6 +1389,7 @@ START_TEST(msacm)
test_prepareheader();
test_acmFormatSuggest();
test_acmFormatTagDetails();
+ test_mp3();
/* Test acmDriverAdd in the end as it may conflict
* with other tests due to codec lookup order */
test_acmDriverAdd();
diff --git a/dlls/winemp3.acm/mpegl3.c b/dlls/winemp3.acm/mpegl3.c
index 37993b4..b6595e6 100644
index 13a6109a77a..b5ba4c6d834 100644
--- a/dlls/winemp3.acm/mpegl3.c
+++ b/dlls/winemp3.acm/mpegl3.c
@@ -215,6 +215,7 @@ static void MPEG3_Reset(PACMDRVSTREAMINSTANCE adsi, AcmMpeg3Data* aad)
@@ -129,7 +128,7 @@ index 37993b4..b6595e6 100644
/* resampling or mono <=> stereo not available
* MPEG3 algo only define 16 bit per sample output
*/
@@ -261,7 +274,7 @@ static LRESULT MPEG3_StreamOpen(PACMDRVSTREAMINSTANCE adsi)
@@ -270,7 +283,7 @@ static LRESULT MPEG3_StreamOpen(PACMDRVSTREAMINSTANCE adsi)
theEnd:
HeapFree(GetProcessHeap(), 0, aad);
adsi->dwDriver = 0L;
@@ -139,5 +138,5 @@ index 37993b4..b6595e6 100644
/***********************************************************************
--
2.9.0
2.13.1