Jacek Caban : include: Add UAS_EXACTLEGACY define.
Alexandre Julliard
julliard at winehq.org
Fri Mar 26 16:03:31 CDT 2021
Module: wine
Branch: master
Commit: 5d11104689c6e0b21a13e450b9a04c89e1ea47e3
URL: https://source.winehq.org/git/wine.git/?a=commit;h=5d11104689c6e0b21a13e450b9a04c89e1ea47e3
Author: Jacek Caban <jacek at codeweavers.com>
Date: Fri Mar 26 16:33:40 2021 +0100
include: Add UAS_EXACTLEGACY define.
Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/urlmon/session.c | 4 ++--
dlls/urlmon/tests/misc.c | 4 ++--
include/urlmon.idl | 2 ++
3 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/dlls/urlmon/session.c b/dlls/urlmon/session.c
index 3a843cd6593..0596c1df75f 100644
--- a/dlls/urlmon/session.c
+++ b/dlls/urlmon/session.c
@@ -514,8 +514,8 @@ static size_t obtain_user_agent(unsigned int version, WCHAR *ret, size_t size)
size_t len = 0;
HKEY key;
- if(version & 0x1000) {
- version &= ~0x1000;
+ if(version & UAS_EXACTLEGACY) {
+ version &= ~UAS_EXACTLEGACY;
if(version == 7)
quirks = TRUE;
else
diff --git a/dlls/urlmon/tests/misc.c b/dlls/urlmon/tests/misc.c
index d64dcc5965d..2b3df65d5fc 100644
--- a/dlls/urlmon/tests/misc.c
+++ b/dlls/urlmon/tests/misc.c
@@ -1515,7 +1515,7 @@ static void test_user_agent(void)
if (i != 7) {
size = sizeof(ua);
- hres = pObtainUserAgentString(i | 0x1000, ua, &size);
+ hres = pObtainUserAgentString(i | UAS_EXACTLEGACY, ua, &size);
ok(hres == S_OK, "ObtainUserAgentString failed: %08x\n", hres);
ok(size == strlen(ua) + 1, "unexpected size %u, expected %u\n", size, strlen(ua) + 1);
ok(!strcmp(ua, str2), "unexpected UA for version %u %s, expected %s\n",
@@ -1523,7 +1523,7 @@ static void test_user_agent(void)
}
size = sizeof(ua);
- hres = pObtainUserAgentString(i != 1 ? i : 0x1007, ua, &size);
+ hres = pObtainUserAgentString(i != 1 ? i : UAS_EXACTLEGACY | 7, ua, &size);
ok(hres == S_OK, "ObtainUserAgentString failed: %08x\n", hres);
ok(size == strlen(ua) + 1, "unexpected size %u, expected %u\n", size, strlen(ua) + 1);
if(i < 8 && i != 1)
diff --git a/include/urlmon.idl b/include/urlmon.idl
index fd8d6ce7bc8..867d3ebc959 100644
--- a/include/urlmon.idl
+++ b/include/urlmon.idl
@@ -2113,6 +2113,8 @@ struct CONFIRMSAFETY
DWORD dwFlags;
};
+cpp_quote("#define UAS_EXACTLEGACY 0x1000")
+
cpp_quote("EXTERN_C const GUID GUID_CUSTOM_CONFIRMOBJECTSAFETY;")
cpp_quote("DEFINE_GUID(CLSID_InternetSecurityManager, 0x7b8a2d94, 0x0ac9, 0x11d1, 0x89, 0x6c, 0x00, 0xc0, 0x4f, 0xB6, 0xbf, 0xc4);")
More information about the wine-cvs
mailing list