File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -44,10 +44,6 @@ namespace winrt::TerminalApp::implementation
4444 {
4545 _args = { value.begin (), value.end () };
4646 _parseResult = _parsed.ParseArgs (_args);
47- if (_parseResult == 0 )
48- {
49- _parsed.ValidateStartupCommands ();
50- }
5147 }
5248
5349 winrt::com_array<winrt::hstring> CommandlineArgs::Commandline ()
Original file line number Diff line number Diff line change @@ -1050,6 +1050,11 @@ namespace winrt::TerminalApp::implementation
10501050 // (or called TerminalWindow::Initialize)
10511051 if (_appArgs->ExitCode () == 0 )
10521052 {
1053+ // The existing logic (before this commit) strictly relied on
1054+ // ValidateStartupCommands() only to be called for new windows.
1055+ // It modifies the actions it stores.
1056+ parsedArgs.ValidateStartupCommands ();
1057+
10531058 // If the size of the arguments list is 1,
10541059 // then it contains only the executable name and no other arguments.
10551060 _hasCommandLineArguments = _appArgs->CommandlineRef ().size () > 1 ;
You can’t perform that action at this time.
0 commit comments