title: select() for UDP connection
body: <p>Can someone explain to me why we use the <code>select()</code> function before <code>recvfrom()</code> (on the server side) instead of before <code>sendto()</code> (on the client side) when waiting for a timeout? It seems to me that the timeout should be on the sender's side.</p>
  
  <pre><code>//EX
  
  CLIENT                              SERVER
  ------                              ------
  select()     /* start timeout */
    sendto()   /* --send packet--&gt; */ recvfrom()
    recvfrom() /*  &lt;--send ACK-- */   sendto()
  </code></pre>
  
  <p>And as long as the ACK has been received before the timeout is reached, the sender could send another file.</p>