I am a newbie in C++ and in winsock programming.
I've taken one FTP library, which uses CBlockingSocket implementation.
The problem is, that there is method CBlockingSocket::Create, which
calls for socket(AF_INET, SOCK_STREAM, 0). It works with a different visual studios( 2008, 2005 ) under different OS ( Vista, Win7, XP).
But there is one machine with VS2005 WinXP, there this method returns INVALID_SOCKET.
I have tried different things and found out, that it will start to work if i will call WSAStartup() before socket(AF_INET, SOCK_STREAM, 0).
In MSDN description of WSAStartup is written, that this function must be called, before any other functions in WinSock.
But why this works on most machines, and on only one computer - it doesn't work?
Any comments? Suggestions? Ideas?
P.S Sorry for my english :)