Hello Francois,

>
Are you sure the FTP component run in the thread's context ? That is it is 
created from the thread's
execute method.
<
Yes, I always have a "ContextStartup" Method in my threads. It is called at 
first on my threads execute before I step into the "while not terminated" loop.

>
Does the slowdown occur when you app just do nothing or when there is a file 
transfer in progress ?
<
Yes the slowdonw occures even thought my application as nothing to to and the 
questioned thread spend most of it's time "Waiting for Events" 
(WaitForMultibleObjects) where I have set the timeout to 1 second.
Manipulating the timeout results in proportional delays.

In the meanwhile I found a hint at MSDN:

>---- Quotation from a NG---
MSDN:

Creating Windows in Threads
Any thread can create a window. The thread that creates the window owns
the window and its associated message queue. Therefore, the thread must
provide a message loop to process the messages in its message queue. In
addition, you must use MsgWaitForMultipleObjects or
MsgWaitForMultipleObjectsEx in that thread, rather than the other wait
functions, so that it can process messages. Otherwise, the system can
become deadlocked when the thread is sent a message while it is waiting.
<---- end quotation

I guess, next thing I try is to use "MsgWaitForMultipleObjects" instead of 
"WaitForMultipleObjects".

Rainer

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://www.elists.org/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to