Log when WindowsTerminal.exe starts (#17745)

as discussed in team sync

(cherry picked from commit 60ac45c2398e3d8f04680559188526b75b29fde8)
Service-Card-Id: 93750273
Service-Version: 1.21
This commit is contained in:
Mike Griese 2024-08-20 10:18:42 -05:00 committed by Dustin Howett
parent 6b6167ec2b
commit 2890e8a3d4

View File

@ -88,6 +88,13 @@ int __stdcall wWinMain(HINSTANCE, HINSTANCE, LPWSTR, int nCmdShow)
TraceLoggingRegister(g_hWindowsTerminalProvider);
::Microsoft::Console::ErrorReporting::EnableFallbackFailureReporting(g_hWindowsTerminalProvider);
TraceLoggingWrite(
g_hWindowsTerminalProvider,
"ExeCreated",
TraceLoggingDescription("Event emitted when the terminal process is started"),
TraceLoggingKeyword(MICROSOFT_KEYWORD_MEASURES),
TelemetryPrivacyDataTag(PDT_ProductAndServiceUsage));
// If Terminal is spawned by a shortcut that requests that it run in a new process group
// while attached to a console session, that request is nonsense. That request will, however,
// cause WT to start with Ctrl-C disabled. This wouldn't matter, because it's a Windows-subsystem