franky
May 10th, 1999, 11:47 PM
i created CSocket CArchives and a CSocketFile then connected to ftp site.
these variables are pointers
if(!(sock=new CSocket)) return FALSE;
if(!(sock->Create())) return FALSE;
//connect to server
if(!(sock->Connect(serverhost,serverport)))
{
err = sock->GetLastError();
strErr.Format("%d", err);
return FALSE;
}
if(!(sockfile=new CSocketFile(sock))) return FALSE;
if(!(arRead=new CArchive(sockfile, CArchive::load))) return FALSE;
if(!(arSend=new CArchive(sockfile, CArchive::store))) return FALSE;
I received the connected signal from microsoft ftp site, the responses was from their server.
after i sent "USER anonymous" command, i tried to use arRead->ReadString(m_data) to read the response from the server, it just freezes on that line of code. can anyone help me with this?
thanks
these variables are pointers
if(!(sock=new CSocket)) return FALSE;
if(!(sock->Create())) return FALSE;
//connect to server
if(!(sock->Connect(serverhost,serverport)))
{
err = sock->GetLastError();
strErr.Format("%d", err);
return FALSE;
}
if(!(sockfile=new CSocketFile(sock))) return FALSE;
if(!(arRead=new CArchive(sockfile, CArchive::load))) return FALSE;
if(!(arSend=new CArchive(sockfile, CArchive::store))) return FALSE;
I received the connected signal from microsoft ftp site, the responses was from their server.
after i sent "USER anonymous" command, i tried to use arRead->ReadString(m_data) to read the response from the server, it just freezes on that line of code. can anyone help me with this?
thanks