News for hackers. Stuff that matters.
Re:Everything you need to know about windsocks by unnouinceput on Sunday November 01, 2020 @03:03AM (#24957919)
90's? On desktop world this is pretty much still in use due to Windows being king on desktop. And if you master Winsock you can still rack in the big bucks even if you ignore everything else.
Re:Everything you need to know about windsocks by the-dude on Sunday November 01, 2020 @03:58AM (#24958159)
By doing what exactly?
Re:Everything you need to know about windsocks by quietbritishjim on Sunday November 01, 2020 @05:14AM (#24958458)
Why not use a wrapper API like ASIO?
Re:Everything you need to know about windsocks by soylentgraham on Sunday November 01, 2020 @05:39AM (#24958566)
Why not just use the API? :)
Re:Everything you need to know about windsocks by quietbritishjim on Monday November 02, 2020 @04:36AM (#24966208)
Advantages:

* Using a wrapper lets you use the same API on different platforms. This is not just for programs that are expected to compile and run on multiple platforms (although that is the main reason); it's also for developers who are expected to write programs for multiple platforms.

* This potentially allows for a cleaner API, because the native OS one has to be careful about backwards compatibility, whereas wrapper APIs can be more carefree about it, at least initially. In the most extreme case, you can use a totally new library with a freshly-designed API. At this point ASIO has stabilised, but you can see it's substantially different from WinSock (albeit it has the same fundamental concepts, of course).

* The underlying OS API generally has to be purely C-based, whereas a wrapper can make use of langauge features, such as C++ features in the case of ASIO. It is sometimes debatable whether it's a benefit to make use of C++ language features! But at least some people would consider it to be.

Disadvantages:

* As discussed above, job security!