🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

I FOUND OUT THE PROBLEM =)

Started by
2 comments, last by kalldrex 23 years, 4 months ago
okay some of you may know i''ve been having trouble with console win32 apps cause they freeze at startup! well i found out the problem was with winsock 2.0. I can live with 1.0 for now but i really think i should use 2.0 later. i know it''s easily upgradeable but any ideas how to fix my problem with 2.0?
ALL YOUR BASE ARE BELONG TO US!!!!
Advertisement
Post your code.

Assuming you''re using Visual Studio, where does the app hang when debugging it?
Well i'm not using my code (lol my code just plain isn't working but i didn't make it from scratch so....). I got one game server to work with downgrading to 1.1 but this other server program jsut doesn't want to work (it keeps hanging at startup like before). I think it's a problem with either the way i'm initializing or (knowing microsoft) the commands for winsock are using functions for winsock 2 and it's causing problems right away. What's a good way in your opionion to initialize winsock for 1.1?

*update*
well i checked the code and the recieving functions and winsock calls are all winsock 1.1 compatible so....

Edited by - kalldrex on February 12, 2001 5:16:49 PM
ALL YOUR BASE ARE BELONG TO US!!!!

#include

int main(int argc, char* argv[])
{
WSADATA wsaData;
int nRet = 0;

if((nRet = WSAStartup(MAKEWORD(2,0), &wsaData)))
{
switch(nRet)
{
case WSASYSNOTREADY:
...
case WSAVERNOTSUPPORTED:
...
case WSAEINPROGRESS:
...
case WSAEPROCLIM:
...
case WSAEFAULT:
...
};
return 1;
}

//MAIN GAME LOOP

WSACleanup();

return 0;
}

This topic is closed to new replies.

Advertisement