title: What is the purpose of listen() in Socket Programming?
body: <p><code>ret = listen(connection_socket, 1);</code>  //allowing one connection in queue</p>
  
  <p>I have opened 2 terminals and ran client process in all 2 terminals at the same time. </p>
  
  <p>Here server is busy in processing client1 data, now client2 is in pending queue. Now queue is full.</p>
  
  <p>At this stage, i have launched 3rd terminal and ran client process. Sine queue is full, connect for this client should return -1 and errno should set to ECONNREFUSED,
  but in this case, connect is returning 0 for client 3 too. Then what is the purpose of <code>listen()</code> system call.</p>