Do not pass a placeholder user-agent string as a fallback when using WinHttp (#1495)

Verified the behavior is now as expected when telemetry policy is turned off.

**Before:**
![image](https://user-images.githubusercontent.com/6527137/106042018-65d64e00-6091-11eb-8741-c6c42cb028d3.png)

**After:**
![image](https://user-images.githubusercontent.com/6527137/106042157-86060d00-6091-11eb-9699-929128eb6ea1.png)
This commit is contained in:
Ahson Khan 2021-01-27 12:31:53 -08:00 committed by GitHub
parent 453d39c577
commit af844a1272
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -189,7 +189,8 @@ void WinHttpTransport::CreateSessionHandle(std::unique_ptr<Details::HandleManage
// Use WinHttpOpen to obtain a session handle.
// The dwFlags is set to 0 - all WinHTTP functions are performed synchronously.
handleManager->m_sessionHandle = WinHttpOpen(
L"WinHTTP Azure SDK",
NULL, // Do not use a fallback user-agent string, and only rely on the header within the
// request itself.
WINHTTP_ACCESS_TYPE_NO_PROXY,
WINHTTP_NO_PROXY_NAME,
WINHTTP_NO_PROXY_BYPASS,