COMPUTER NETWORKING

APPLICATION LAYER

SOCKET INTERFACE PROGRAMMING

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
This function in socket assocates and reserves a port for use by the socket.
A
Listen
B
create
C
bind
D
connect
Explanation: 

Detailed explanation-1: -Answer: Bind() function in socket programming is used to associate the socket with local address i.e. IP Address, port and address family.

Detailed explanation-2: -When a socket has both an IP address and a port number it is said to be ‘bound to a port’, or ‘bound to an address’. A bound socket can receive data because it has a complete address. The process of allocating a port number to a socket is called ‘binding’.

Detailed explanation-3: -close (Socket-Desc) This function is used to close the socket and free the Socket-Desc.

There is 1 question to complete.