Commit 5c654b48 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

urlmon: Avoid useless InternetQueryOptionW call.

parent bebcce32
...@@ -79,18 +79,13 @@ static LPWSTR query_http_info(HttpProtocol *This, DWORD option) ...@@ -79,18 +79,13 @@ static LPWSTR query_http_info(HttpProtocol *This, DWORD option)
return ret; return ret;
} }
static inline BOOL set_security_flag(HttpProtocol *This, DWORD new_flag) static inline BOOL set_security_flag(HttpProtocol *This, DWORD flags)
{ {
DWORD flags, size = sizeof(flags);
BOOL res; BOOL res;
res = InternetQueryOptionW(This->base.request, INTERNET_OPTION_SECURITY_FLAGS, &flags, &size); res = InternetSetOptionW(This->base.request, INTERNET_OPTION_SECURITY_FLAGS, &flags, sizeof(flags));
if(res) {
flags |= new_flag;
res = InternetSetOptionW(This->base.request, INTERNET_OPTION_SECURITY_FLAGS, &flags, size);
}
if(!res) if(!res)
ERR("Failed to set security flag(s): %x\n", new_flag); ERR("Failed to set security flags: %x\n", flags);
return res; return res;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment