Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

OPTION dialog takes 20 seconds to close

May
13,834
211
I tested this under a variety of conditions, most recently in a console with no plugins loaded. It's the same in other scenarios.

Issue the OPTION command and in the dialog, press OK. I see the spinning blue ring immediately. If I do anything I'll get the "TCC not responding" title. After 20 seconds, the dialog closes leaving TCC apparently OK.
 
This affects all my TCCs (v24 -) to some extent. It's the same after a computer restart. According to ProcessMonitor, v34 does this, over and over, for 20 seconds.

1738424149027.webp
 

Attachments

  • optionpic.webp
    optionpic.webp
    64.9 KB · Views: 6
I see a delay the first time I do this, but it's closer to five seconds than 20.

Perhaps you need to load some plugins.
 
I'm glad someone else sees something! It's the same with/without plugins, INI file, TCSTART. In older TCCs it can be more like 5 seconds (and quicker the second time). In TCC v34 it's always 20 sec.
 
If you do an OPTION and do not make any changes, OPTION will not (re)write TCMD.INI.
Having made no changes, "Cancel" closes the dialog immediately; "OK" takes 20 sec. and does that stuff I reported earlier over and over.
 
Interesting: If I'm in TCMD v34 and, from the ribbon, OPTION\TCC ... no changes ... OK, it takes 20 seconds to close. If, again from the ribbon, OPTION\TakeCommand ... no changes ... OK, it takes 7 seconds to close.
 
Did you get any Windows updates recently?
Last ones were 1/15, cumulative, security, .NET, VS22, VS19

Intel/Dell firmware on 1/16

Defender definitions every day.

This has got to be the system since it affects old TCCs. But it seems to affect only TCC.
 
I was pressing OK immediately so I was on the Startup page. I just tried a couple other pages ... got 15 sec., 25 sec..
 
Try adding this to your TCMD.INI:

UpdateINI=NO

(Not as a permanent setting, but to determine whether the TCC code is going to be called at all after the property sheet returns.)
Which [Section] of the INI file?
 
Since it happens in older versions as well, RTL changes are excused.

There's only one Windows API called in the routine that's skipped by UpdateINI=NO, and that's WritePrivateProfileString. 99% chance that Microsoft bollixed that API in a recent update.

Only quick fix for that would be for me to write my own version, and that will take a while using one hand. (Sling doesn't come off for another 4.5 weeks.)
 
A quick Google search turned up several reports of WritePrivateProfileString getting dramatically slower after a 24H2 update. Microsoft's response thus far is "that's an obsolete function, you should be writing everything to the registry".

So unlikely to get much help from them anytime soon.
 
This takes 20 seconds also.

Code:
    for ( INT i=0; i<100; i++ )
        WritePrivateProfileStringW(L"4NT", L"KeyName", L"Value", L"d:\\tc34\\tcmd.ini.bak");

And this, naming an empty file, is more or less instantaneous.

Code:
    for ( INT i=0; i<100; i++ )
        WritePrivateProfileStringW(L"4NT", L"KeyName", L"Value", L"d:\\tc34\\tcmd.ini.xxx");

It seems to be slow reading the file.
 
If you do "Apply" for each change in the OPTION dialog and when you're done, "Cancel", you get all the changes and no delay.
 
Back
Top