IOW, what is the proper way to assign a worker thread to a Ftp Client 
instance?

Best Regards,

SZ

----- Original Message ----- 
From: "Fastream Technologies" <[EMAIL PROTECTED]>
To: "ICS support mailing" <twsocket@elists.org>
Sent: Monday, October 24, 2005 11:13 AM
Subject: [twsocket] Making TFtpServer MT: the proper way


> Hello,
>
> I want to make our async FTP server, one thread-per CPU MT design. We 
> assign
> threads to instances in OnClientConnect, and I have the following code:
>
> void __fastcall ftpServerThread::FtpServerClientConnect(
> TObject *Sender,
>       TFtpCtrlSocket *Client,
> WORD AError)
> {
>        releaseCriticalSection(FtpServer->connectDisconnectClient);
>
>        ftpServerClientClass *ftpClient = (ftpServerClientClass*)Client;
>
>        ftpClient->affinityThread =
> ftpServerClientThreadManager->getFTPThread();
>        ftpClient->server = this;
>
>        ftpClient->ThreadDetach();
>        PostThreadMessage(ftpClient->affinityThread->ThreadID,
> WM_FTP_CLIENT_THREAD_ATTACH, (unsigned int)(void*)ftpClient, 0);
> }
> //---------------------------------------------------------------------------
>
> Now the control connection works well but after a directory listing, it 
> does
> not return the 150 reply! Do I need to do anything else in
> (Retr/Stor)Session(Connected/Closed)?
>
> Best Regards,
>
> SubZ
>
> -- 
> 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 

-- 
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