I am aware that, a C program in the ANSI standard can be compiled in both Windows on both Linux.
But when it comes to using sockets ? Is this not part of the ANSI C
pattern? Because when I use sockets in Windows, I have to use a library called "Winsock.h"
, on Linux, that library does not exist, and it uses another library called "socket.h"
. In this case, a program in Windows that uses the "Winsock.h"
library will give error when compiled in a Linux, and vise versa. However, Sockets are not in the default?
Another thing is the fork()
function, this function exists only in Linux to do threads, I believe. So this function, which is non-existent in Windows, is out of the standard ANSI C
?