Peter
This works for me.
#include <winsock.h>
#pragma comment(lib,"wsock32.lib")
int main(int argc, char *argv[])
{
int nRetCode;
WSADATA wsData;
WORD wVersionRequested;
wVersionRequested = MAKEWORD(1,1);
nRetCode = WSAStartup(wVersionRequested,&wsData);
if(nRetCode != 0)
{
printf("Windows socket initialization failed: Error:
%d\n",GetLastError());
exit(0);
}
return(nRetCode);
}
Marcus
----- Original Message -----
From: "Peter Aben" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, December 24, 2002 5:35 AM
Subject: Socket call fails with OpenSSL 0.9.6h on Win32
> I have used OpenSSL 0.9.6c in our application successfully on various
> platforms.
> After upgrading to 0.9.6h, on the Windows platform the socket() call fails
> with an error code 10093 (successful WSAStartup not yet performed).
> For compatibility reasons I don't use Winsock2, so no WSAStartup should be
> necessairy (and it wasn't with 0.9.6c). When I replace the new (0.9.6h)
SSL
> dll's with the old ones (0.9.6c), it works fine again (without recompiling
> my application). The specific platform is NT4/SP6a. I use the default
> compilation procedure that comes with OpenSSL. The compiler is MSVC 5.00.
> Is anyone familiar with this problem?
>
>
> ______________________________________________________________________
> OpenSSL Project http://www.openssl.org
> User Support Mailing List [EMAIL PROTECTED]
> Automated List Manager [EMAIL PROTECTED]
----- Original Message -----
From: "Peter Aben" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, December 24, 2002 5:35 AM
Subject: Socket call fails with OpenSSL 0.9.6h on Win32
> I have used OpenSSL 0.9.6c in our application successfully on various
> platforms.
> After upgrading to 0.9.6h, on the Windows platform the socket() call fails
> with an error code 10093 (successful WSAStartup not yet performed).
> For compatibility reasons I don't use Winsock2, so no WSAStartup should be
> necessairy (and it wasn't with 0.9.6c). When I replace the new (0.9.6h)
SSL
> dll's with the old ones (0.9.6c), it works fine again (without recompiling
> my application). The specific platform is NT4/SP6a. I use the default
> compilation procedure that comes with OpenSSL. The compiler is MSVC 5.00.
> Is anyone familiar with this problem?
>
>
> ______________________________________________________________________
> OpenSSL Project http://www.openssl.org
> User Support Mailing List [EMAIL PROTECTED]
> Automated List Manager [EMAIL PROTECTED]
---------------------------------------------
Introducing NetZero Long Distance
1st month Free!
Sign up today at: www.netzerolongdistance.com
______________________________________________________________________
OpenSSL Project http://www.openssl.org
User Support Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]