title: Does send() always send whole buffer?
body: <p><code>send()</code> shall return the number of bytes sent or error code, but all examples that I found check it only with error codes, but not with the number of bytes sent.</p>
  
  <pre><code>//typical example
  int cnt=send(s,query,strlen(query),0);
  if (cnt &lt; 0) return(NULL);
  //Hey, what about cnt &lt; strlen(query)?
  </code></pre>