Discussion:
What is difference sockets programming on UNIX and Windows.?
(too old to reply)
li
2010-08-15 15:15:10 UTC
Permalink
Hello, I am is a new-baby.
I want know what is difference sockets programming on UNIX and Windows.
The same networks programming as sockets programming ?
Dan Rogers
2010-08-18 15:36:42 UTC
Permalink
Windows has a Berekley sockets API very similar to what you are familiar
with on Unix. Windows also has its own sockets API and the function names
start with "WSA." You can use the Berkeley API but at the start of your
program you need to call the Windows function WSAStartup().

"li" <***@gmail.com> wrote in message news:***@god...
Hello, I am is a new-baby.
I want know what is difference sockets programming on UNIX and Windows.
The same networks programming as sockets programming ?
m
2010-08-21 01:04:43 UTC
Permalink
More importantly, the *NIX IO paradigm will function on Windows but perform
poorly; and good Windows programming is incompatible with *NIX.

In *NIX, the select model is preferred because it eliminates blocking IO and
allows threads to poll for 'packets'; but on Windows, the OS overhead is
different and the select model can be outperformed by blocking IO; and both
can be beaten by the IOCP paradigm, for which there is no *NIX analog.

All of that being said, the theory of network stacks and protocols is
identical on ALL platforms including Windows and *NIX. it is a layered
architecture where (as a simplified description) NIC drivers provide packets
to protocol drivers and protocol drivers interface with applications thru
sockets.
Post by Dan Rogers
Windows has a Berekley sockets API very similar to what you are familiar
with on Unix. Windows also has its own sockets API and the function names
start with "WSA." You can use the Berkeley API but at the start of your
program you need to call the Windows function WSAStartup().
Hello, I am is a new-baby.
I want know what is difference sockets programming on UNIX and Windows.
The same networks programming as sockets programming ?
Loading...