Valhalla Legends Archive

Programming => Battle.net Bot Development => Topic started by: ThatOldFalcon on June 24, 2003, 03:44 PM

Title: Help on winsock
Post by: ThatOldFalcon on June 24, 2003, 03:44 PM
I have been trying to learn the basics of winsock stuff but none of the books I looked in were helpful on this topic. Can anyone tell me a good book or other source for help with winsock connection stuff?
Title: Re:Help on winsock
Post by: Eibro on June 24, 2003, 03:58 PM
What_language?
Title: Re:Help on winsock
Post by: ______ on June 24, 2003, 05:56 PM
winsocks, my guess some type of VB?
Title: Re:Help on winsock
Post by: DarkMinion on June 24, 2003, 06:16 PM
What?  C++ doesn't use winsock?  ::)
Title: Re:Help on winsock
Post by: Camel on June 24, 2003, 07:49 PM
Quote from: DarkMinion on June 24, 2003, 06:16 PM
What?  C++ doesn't use winsock?  ::)

Nobody calls them "winsocks" in C, just "sockets."
Title: Re:Help on winsock
Post by: DarkMinion on June 24, 2003, 08:12 PM
Really?  I suppose that's why most of the socket API functions start with "WS", which stands for "winsock".  Please Camel, you make it too easy...
Title: Re:Help on winsock
Post by: Zakath on June 24, 2003, 10:38 PM
He has a point though...in VB the actual object you put on the form is called a "Winsock," isn't it?

In C++ (and I know you know this, DM :P) you declare it as a socket.
Title: Re:Help on winsock
Post by: Yoni on June 25, 2003, 01:01 AM
But you still #include winsock2.h!
Title: Re:Help on winsock
Post by: iago on June 25, 2003, 04:40 AM
Yes, they both eventually use the winsock api, which uses sockets.  The socket your declare is a socket, but you need winsock to play with it.
Title: Re:Help on winsock
Post by: Camel on June 25, 2003, 11:07 AM
I didn't say it is incorrect to call them winsocks in C++; it's perfectly correct. However, nobody (that I know at least) puts the extra three letters in because, unless one is trying to specify the difference between the two, it's practically redundant.
Title: Re:Help on winsock
Post by: iago on June 25, 2003, 06:30 PM
I do, and you know me.  If I'm talking about linux or general sockets, I call them sockets.  But if I'm talking about using them in windows, I call it winsock :)
Title: Re:Help on winsock
Post by: Camel on June 25, 2003, 06:44 PM
Quote from: iago on June 25, 2003, 06:30 PM
I do, and you know me.  If I'm talking about linux or general sockets, I call them sockets.  But if I'm talking about using them in windows, I call it winsock :)

There is no spoon!
Title: Re:Help on winsock
Post by: Zakath on June 25, 2003, 09:18 PM
Alrighty, from now on I will consistently say "Berkeley sockets." :P
Title: Re:Help on winsock
Post by: Camel on June 25, 2003, 11:03 PM
Quote from: Zakath on June 25, 2003, 09:18 PM
Alrighty, from now on I will consistently say "Berkeley sockets." :P

I doubt that highly.
Title: Re:Help on winsock
Post by: smoke on June 26, 2003, 12:17 AM
Berkeley doesn't quite fully encapsulate the true name.  BSD Sockets or more precisely, Berkeley Software Distribution Sockets.  So, if you want to start calling them by their full names:

Windows Sockets
Berkeley Software Distribution Sockets

Now, if people start pasting those full names into posts, somebody needs to grab either the riffle or whip.  I don't think anybody wants to read a post where Berkeley Software Distribution Sockets amounts for more than 50% of the entire post.  That's the reason for having TLA's (three letter acroynms) and abbreviations.

Winsock
BSD sockets

furthermore, Winsock is actually MS's slight deviation of standard technology which they proceeded to name after their own software.  (no suprised there eh?)  It actually should be named something like Windows BSD sockets or MSBSD sockets.  Oh god that would be sacreligous though.  That is why in general it is best to refer to all forms and derivations of BSD sockets as just plain sockets.