From 3a7bd03da0428ec4d005bff041d532182a077bbd Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Mon, 20 Jun 2016 21:32:22 +0200 Subject: [PATCH] wininet: Fixed tests on win10. Signed-off-by: Jacek Caban Signed-off-by: Alexandre Julliard --- dlls/wininet/tests/internet.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/dlls/wininet/tests/internet.c b/dlls/wininet/tests/internet.c index d76276831a8..db662a20ba9 100644 --- a/dlls/wininet/tests/internet.c +++ b/dlls/wininet/tests/internet.c @@ -1067,7 +1067,8 @@ static void test_IsDomainLegalCookieDomainW(void) static void test_PrivacyGetSetZonePreferenceW(void) { - DWORD ret, zone, type, template, old_template; + DWORD ret, zone, type, template, old_template, pref_size = 0; + WCHAR pref[256]; zone = 3; type = 0; @@ -1078,6 +1079,14 @@ static void test_PrivacyGetSetZonePreferenceW(void) ret = pPrivacyGetZonePreferenceW(zone, type, &old_template, NULL, NULL); ok(ret == 0, "expected ret == 0, got %u\n", ret); + trace("template %u\n", old_template); + + if(old_template == PRIVACY_TEMPLATE_ADVANCED) { + pref_size = sizeof(pref)/sizeof(WCHAR); + ret = pPrivacyGetZonePreferenceW(zone, type, &old_template, pref, &pref_size); + ok(ret == 0, "expected ret == 0, got %u\n", ret); + } + template = 5; ret = pPrivacySetZonePreferenceW(zone, type, template, NULL); ok(ret == 0, "expected ret == 0, got %u\n", ret); @@ -1088,7 +1097,7 @@ static void test_PrivacyGetSetZonePreferenceW(void) ok(template == 5, "expected template == 5, got %u\n", template); template = 5; - ret = pPrivacySetZonePreferenceW(zone, type, old_template, NULL); + ret = pPrivacySetZonePreferenceW(zone, type, old_template, pref_size ? pref : NULL); ok(ret == 0, "expected ret == 0, got %u\n", ret); }