linux socket
1,socket define:
socket type:
socket_stream: tcp
socket_dgram: udp
2,create socket
socket function:
int socket(int domain,int type,int protocol);
|| || ||
PF_INET TCP/UDP 0
3,bind socket:
bind function:
int bind(int sockfd,struct sockaddr *my_addr,int addrlen);
…………………………………………………………………………