wininet: Fixed tests on win10.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jacek Caban 2016-06-20 21:32:22 +02:00 committed by Alexandre Julliard
parent 68dddd8d89
commit 3a7bd03da0
1 changed files with 11 additions and 2 deletions

View File

@ -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);
}