Signed-off-by: Zebediah Figura z.figura12@gmail.com --- dlls/msvfw32/tests/msvfw.c | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-)
diff --git a/dlls/msvfw32/tests/msvfw.c b/dlls/msvfw32/tests/msvfw.c index 3fe6702..c6fe0f2 100644 --- a/dlls/msvfw32/tests/msvfw.c +++ b/dlls/msvfw32/tests/msvfw.c @@ -303,18 +303,9 @@ static void test_ICInfo(void)
found++; /* Test getting info with a different case - bug 41602 */ - if (fcc[0] & 0x20) - { - fcc[0] &= ~0x20; - ok(ICInfo(info.fccType, info.fccHandler, &info2), - "ICInfo failed on fcc 0x%08x using lowercase fccHandler\n", info.fccHandler); - } - else - { - fcc[0] |= 0x20; - ok(ICInfo(info.fccType, info.fccHandler, &info2), - "ICInfo failed on fcc 0x%08x using uppercase fccHandler\n", info.fccHandler); - } + fcc[0] ^= 0x20; + ok(ICInfo(info.fccType, info.fccHandler, &info2), + "ICInfo failed on fcc 0x%08x\n", info.fccHandler); } ok(found != 0, "expected at least one codec\n"); }
Fixes https://bugs.winehq.org/show_bug.cgi?id=44489
Signed-off-by: Zebediah Figura z.figura12@gmail.com --- dlls/msvfw32/msvideo_main.c | 2 ++ dlls/msvfw32/tests/msvfw.c | 6 ++++++ 2 files changed, 8 insertions(+)
diff --git a/dlls/msvfw32/msvideo_main.c b/dlls/msvfw32/msvideo_main.c index d49ea74..7a3573c 100644 --- a/dlls/msvfw32/msvideo_main.c +++ b/dlls/msvfw32/msvideo_main.c @@ -297,11 +297,13 @@ DWORD WINAPI VideoForWindowsVersion(void) static BOOL ICInfo_enum_handler(const char *drv, unsigned int nr, void *param) { ICINFO *lpicinfo = param; + DWORD fccType = mmioStringToFOURCCA(drv, 0); DWORD fccHandler = mmioStringToFOURCCA(drv + 5, 0);
if (lpicinfo->fccHandler != nr && compare_fourcc(lpicinfo->fccHandler, fccHandler)) return FALSE;
+ lpicinfo->fccType = fccType; lpicinfo->fccHandler = fccHandler; lpicinfo->dwFlags = 0; lpicinfo->dwVersion = 0; diff --git a/dlls/msvfw32/tests/msvfw.c b/dlls/msvfw32/tests/msvfw.c index c6fe0f2..beeca9f 100644 --- a/dlls/msvfw32/tests/msvfw.c +++ b/dlls/msvfw32/tests/msvfw.c @@ -294,6 +294,7 @@ static void test_ICInfo(void) for (i = found = 0; ICInfo(0, i, &info); i++) { trace("Codec name: %s, fccHandler: 0x%08x\n", wine_dbgstr_w(info.szName), info.fccHandler); + ok(info.fccType, "expected nonzero fccType\n");
ok(ICInfo(info.fccType, info.fccHandler, &info2), "ICInfo failed on fcc 0x%08x\n", info.fccHandler); @@ -308,6 +309,11 @@ static void test_ICInfo(void) "ICInfo failed on fcc 0x%08x\n", info.fccHandler); } ok(found != 0, "expected at least one codec\n"); + + memset(&info, 0, sizeof(info)); + ok(!ICInfo(ICTYPE_VIDEO, mmioFOURCC('f','a','k','e'), &info), "expected failure\n"); + ok(info.fccType == ICTYPE_VIDEO, "got 0x%08x\n", info.fccType); + ok(info.fccHandler == mmioFOURCC('f','a','k','e'), "got 0x%08x\n", info.fccHandler); }
START_TEST(msvfw)
Zebediah Figura z.figura12@gmail.com writes:
Fixes https://bugs.winehq.org/show_bug.cgi?id=44489
Signed-off-by: Zebediah Figura z.figura12@gmail.com
dlls/msvfw32/msvideo_main.c | 2 ++ dlls/msvfw32/tests/msvfw.c | 6 ++++++ 2 files changed, 8 insertions(+)
This fails here:
../../../tools/runtest -q -P wine -T ../../.. -M msvfw32.dll -p msvfw32_test.exe.so msvfw && touch msvfw.ok msvfw.c:299: Test failed: ICInfo failed on fcc 0x616d692e msvfw.c:299: Test failed: ICInfo failed on fcc 0x61736d2e msvfw.c:299: Test failed: ICInfo failed on fcc 0x67736d2e msvfw.c:299: Test failed: ICInfo failed on fcc 0x61336c2e msvfw.c:299: Test failed: ICInfo failed on fcc 0x67736d2e Makefile:218: recipe for target 'msvfw.ok' failed make: *** [msvfw.ok] Error 5
On 12/02/18 13:32, Alexandre Julliard wrote:
Zebediah Figura z.figura12@gmail.com writes:
Fixes https://bugs.winehq.org/show_bug.cgi?id=44489
Signed-off-by: Zebediah Figura z.figura12@gmail.com
dlls/msvfw32/msvideo_main.c | 2 ++ dlls/msvfw32/tests/msvfw.c | 6 ++++++ 2 files changed, 8 insertions(+)
This fails here:
../../../tools/runtest -q -P wine -T ../../.. -M msvfw32.dll -p msvfw32_test.exe.so msvfw && touch msvfw.ok msvfw.c:299: Test failed: ICInfo failed on fcc 0x616d692e msvfw.c:299: Test failed: ICInfo failed on fcc 0x61736d2e msvfw.c:299: Test failed: ICInfo failed on fcc 0x67736d2e msvfw.c:299: Test failed: ICInfo failed on fcc 0x61336c2e msvfw.c:299: Test failed: ICInfo failed on fcc 0x67736d2e Makefile:218: recipe for target 'msvfw.ok' failed make: *** [msvfw.ok] Error 5
Ah, so it seems that first patch was necessary after all. I had originally meant it as part of a series migrating the Drivers32 section to the registry, but it is also necessary for these tests.
In that case would you please review the original series of 3 patches as sent? Thanks.