Cancelation of Refresh after Tab-Switch

Here you can propose new features, make suggestions etc.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
samot
Junior Member
Junior Member
Posts: 56
Joined: 2003-02-21, 11:53 UTC
Location: Koblenz, Germany
Contact:

Cancelation of Refresh after Tab-Switch

Post by *samot »

Following situation

I have three tabs with different directories open:
a) c:\temp
b) z:\ (network drive)
c) \\remotecomputer\c$

I'm working on a (local drive), while my network connection will got lost.

Now I switch the tab to b (the network drive) -> TC realize quickly, that I have no network connection and shows me my c-drive again (in the second tab).

But if I swicht to the third tab, the TC tries for at least an halfe minute to access the remote computer and I have to wait until it realize, that this path is not longer aviable (TC is blocked and not responding following to the task manager). It happens too, if the remote computer has no longer a network connection.

So it would be nice, if I could cancel the request simple by pressing the ESC-key.

best regards

Thomas
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48097
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Please try this: in wincmd.ini section [Configuration] add the line

ThreadFindFirst=1

It may or may not work, so please report what it does in your case!
Author of Total Commander
https://www.ghisler.com
samot
Junior Member
Junior Member
Posts: 56
Joined: 2003-02-21, 11:53 UTC
Location: Koblenz, Germany
Contact:

Post by *samot »

Thanks, it seems to work.

TC shows now after about 5 sec a small window "Connecting to ..." with a Cancel-Button. If I press it, it still shows me the remote path in the head line of the tab, but the file list is empty.

After several seconds TC realize, that it hasn't anything in the file list and ask me for another drive to show.

best regards

Thomas
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48097
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

If I press it, it still shows me the remote path in the head line of the tab, but the file list is empty.
Can you change drive at this moment, e.g. to c:\ ?
Author of Total Commander
https://www.ghisler.com
samot
Junior Member
Junior Member
Posts: 56
Joined: 2003-02-21, 11:53 UTC
Location: Koblenz, Germany
Contact:

Post by *samot »

No, not until it shows me the c:\-drive (but it is much more faster, that I can work again as before).

best regards

Thomas
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48097
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Hmm, sounds like TC is still trying to access some remote path at this moment. Can you please check with filemon what is going on?
Author of Total Commander
https://www.ghisler.com
samot
Junior Member
Junior Member
Posts: 56
Joined: 2003-02-21, 11:53 UTC
Location: Koblenz, Germany
Contact:

Post by *samot »

OK, here is the FILEMON-Log.

Btw: Why does TC read the ini file every time I move my mouse from another application to TC and from TC to another appl.? Would it not make more sense to save the read entry in a global var?

Code: Select all

- Mouse hover over TC window
124	13:58:21	TOTALCMD.EXE:3272	OPEN	C:\WINDOWS\WINCMD.INI	SUCCESS	Options: Open  Access: All	
125	13:58:21	TOTALCMD.EXE:3272	OPEN	C:\WINDOWS\WINCMD.INI	SUCCESS	Options: Open  Access: All	
126	13:58:21	TOTALCMD.EXE:3272	QUERY INFORMATION	C:\WINDOWS\WINCMD.INI	SUCCESS	Length: 10453	
127	13:58:21	TOTALCMD.EXE:3272	CLOSE	C:\WINDOWS\WINCMD.INI	SUCCESS		
128	13:58:21	TOTALCMD.EXE:3272	LOCK	C:\WINDOWS\WINCMD.INI	SUCCESS	Excl: No Offset: 0 Length: -1	
129	13:58:21	TOTALCMD.EXE:3272	QUERY INFORMATION	C:\WINDOWS\WINCMD.INI	SUCCESS	Length: 10453	
130	13:58:21	TOTALCMD.EXE:3272	READ 	C:\WINDOWS\WINCMD.INI	SUCCESS	Offset: 0 Length: 10453	
131	13:58:21	TOTALCMD.EXE:3272	UNLOCK	C:\WINDOWS\WINCMD.INI	RANGE NOT LOCKED	Offset: 0 Length: -1	
132	13:58:21	TOTALCMD.EXE:3272	CLOSE	C:\WINDOWS\WINCMD.INI	SUCCESS		
133	13:58:21	TOTALCMD.EXE:3272	OPEN	C:\WINDOWS\WINCMD.INI	SUCCESS	Options: Open  Access: All	
134	13:58:21	TOTALCMD.EXE:3272	OPEN	C:\WINDOWS\WINCMD.INI	SUCCESS	Options: Open  Access: All	
135	13:58:21	TOTALCMD.EXE:3272	QUERY INFORMATION	C:\WINDOWS\WINCMD.INI	SUCCESS	Length: 10453	
136	13:58:21	TOTALCMD.EXE:3272	CLOSE	C:\WINDOWS\WINCMD.INI	SUCCESS		
137	13:58:21	TOTALCMD.EXE:3272	LOCK	C:\WINDOWS\WINCMD.INI	SUCCESS	Excl: No Offset: 0 Length: -1	
138	13:58:21	TOTALCMD.EXE:3272	QUERY INFORMATION	C:\WINDOWS\WINCMD.INI	SUCCESS	Length: 10453	
139	13:58:21	TOTALCMD.EXE:3272	READ 	C:\WINDOWS\WINCMD.INI	SUCCESS	Offset: 0 Length: 10453	
140	13:58:21	TOTALCMD.EXE:3272	UNLOCK	C:\WINDOWS\WINCMD.INI	RANGE NOT LOCKED	Offset: 0 Length: -1	
141	13:58:21	TOTALCMD.EXE:3272	CLOSE	C:\WINDOWS\WINCMD.INI	SUCCESS		

- Tried to switch to the remote tab
142	13:58:30	TOTALCMD.EXE:3272	OPEN	\\psnotekp\temp\	BAD NETWORK PATH	Options: Open Directory  Access: All	

- the separate Connecting to ... was showed
143	13:58:33	TOTALCMD.EXE:3272	QUERY INFORMATION	C:\Programme\TotalCmd\TOTALCMD.EXE	SUCCESS	Attributes: A	
144	13:58:33	TOTALCMD.EXE:3272	QUERY INFORMATION	C:\Programme\TotalCmd\TOTALCMD.EXE	SUCCESS	Attributes: A	
145	13:58:33	TOTALCMD.EXE:3272	QUERY INFORMATION	C:\Programme\TotalCmd\TOTALCMD.EXE	SUCCESS	Attributes: A	

- Cancel pressed
146	13:58:37	TOTALCMD.EXE:3272	READ 	C:\WINDOWS\CSC\00000001	SUCCESS	Offset: 0 Length: 64	
147	13:58:37	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: Traverse	
148	13:58:37	TOTALCMD.EXE:3272	CLOSE	C:\FujiLSB\	SUCCESS		
149	13:58:37	TOTALCMD.EXE:3272	OPEN	\\psnotekp\temp	BAD NETWORK PATH	Options: Open Directory  Access: Traverse	
150	13:58:37	TOTALCMD.EXE:3272	OPEN	C:\Dokumente und Einstellungen\thofra\Eigene Dateien	IS DIRECTORY	Options: Open  Access: All	
151	13:58:37	TOTALCMD.EXE:3272	OPEN	C:\Dokumente und Einstellungen\thofra\Eigene Dateien\	SUCCESS	Options: Open  Access: All	
152	13:58:37	TOTALCMD.EXE:3272	CLOSE	C:\Dokumente und Einstellungen\thofra\Eigene Dateien\	SUCCESS		
153	13:58:37	TOTALCMD.EXE:3272	OPEN	C:\Dokumente und Einstellungen\thofra\Eigene Dateien	SUCCESS	Options: Open  Access: All	
154	13:58:37	TOTALCMD.EXE:3272	CLOSE	C:\Dokumente und Einstellungen\thofra\Eigene Dateien	SUCCESS		
155	13:58:37	TOTALCMD.EXE:3272	OPEN	C:\FujiLSB	IS DIRECTORY	Options: Open  Access: All	
156	13:58:37	TOTALCMD.EXE:3272	OPEN	C:\FujiLSB\	SUCCESS	Options: Open  Access: All	
157	13:58:37	TOTALCMD.EXE:3272	CLOSE	C:\FujiLSB\	SUCCESS		
158	13:58:37	TOTALCMD.EXE:3272	OPEN	C:\FujiLSB	SUCCESS	Options: Open  Access: All	
159	13:58:37	TOTALCMD.EXE:3272	CLOSE	C:\FujiLSB	SUCCESS		

- the chose another Drive Dialog was showed
160	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
161	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: *	
162	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation	
163	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
164	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: Acucorp	
165	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
166	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
167	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: compASS.LSB	
168	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
169	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
170	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: compASS.LSB_bak	
171	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
172	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
173	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: cygwin	
174	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
175	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
176	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: Dokumente und Einstellungen	
177	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
178	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
179	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: FLSB941	
180	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
181	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
182	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: FujiLSB	
183	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
184	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
185	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: FujiYAK	
186	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
187	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
188	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: I386	
189	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
190	13:58:40	TOTALCMD.EXE:3272	OPEN	C:\	SUCCESS	Options: Open Directory  Access: All	
191	13:58:40	TOTALCMD.EXE:3272	DIRECTORY	C:\	SUCCESS	FileBothDirectoryInformation: MSOCache	
192	13:58:40	TOTALCMD.EXE:3272	CLOSE	C:\	SUCCESS		
best regards

Thomas
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48097
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Interesting - I will check what options are read.
Author of Total Commander
https://www.ghisler.com
Genghis86
Junior Member
Junior Member
Posts: 87
Joined: 2003-12-07, 02:02 UTC
Location: United States

Post by *Genghis86 »

Christian, Vista supports cancellation of network I/O. So when you try to list files on a network share that is down, you should be able to cancel your request.

Does TC 7 include support for that?
Genghis86
Junior Member
Junior Member
Posts: 87
Joined: 2003-12-07, 02:02 UTC
Location: United States

Post by *Genghis86 »

From Mark Russinovich:

http://www.microsoft.com/technet/technetmag/issues/2007/02/VistaKernel/default.aspx
Probably the most visible change in the I/O system from an end-user perspective is Windows Vista support for canceling synchronous I/O operations. If you've ever performed a net view command or attempted to access a share to an off-line remote system using Windows XP or Windows Server® 2003, you've experienced the problems with I/O operations that can't be canceled: the command or file browser won't respond until a network timeout expires. An application has no choice but to wait until the operation fails because there's no way for it to tell the device driver executing the I/O that it doesn't care about the I/O anymore.

In Windows Vista most I/O operations can be canceled, including the open file I/O that Net View and Explorer use. Applications have to be updated to respond to end-user requests to cancel I/O, however, and many of the Windows Vista utilities that interact with devices that have timeouts have the necessary support. The file open and save dialogs that are used by virtually every Windows application, including third-party applications, for example, now enable their Cancel button while trying to display the contents of a folder. The Net command also cancels its synchronous I/O when you press Ctrl+C.

You can see the benefits of I/O cancellation by opening a command prompt on Windows Vista and typing:
net view \\nonexistentmachine
The command will hang while Windows tries to contact the nonexistent system, but you can type Ctrl+C to terminate it. In Windows XP, Ctrl+C has no effect and the command doesn't return until the network operation times out.
Genghis86
Junior Member
Junior Member
Posts: 87
Joined: 2003-12-07, 02:02 UTC
Location: United States

Post by *Genghis86 »

User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48097
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I have seen this too, but it was not really necessary to use - I can just let the connection hang in the background. See the discussion in the English forum. But it would probably be an additional benefit. But I feat that some hardware drivers will crash when this function is called - driver support isn't very good yet on Vista.
Author of Total Commander
https://www.ghisler.com
Post Reply