title: Python Socket Flush
body: <p>I am trying to make sure that every time I call the socket.send function my buffer is sent (flushed) to my server (which is in C using unix socket).</p>
  
  <p>From my understanding (and from what I see on this board) just disabling the naggle algo. should do it but my server still receive my data in chunk of 4096 bytes (default set)...</p>
  
  <p>Im using the following code in Python v2.5.4:</p>
  
  <pre><code> self.sck = socket( AF_INET, SOCK_STREAM )
  
   self.sck.setsockopt( IPPROTO_TCP, TCP_NODELAY, 1 ) # That doesn't seems to work...
  
   self.sck.connect( ( "127.0.0.1", "12345" ) )
  
   while( 1 ):
        self.sck.send( "test\n" )
        self.sck.send( "" ) # Still trying to flush...
  </code></pre>
  
  <p>Enabling/Disabling TCP_NODELAY seems that have no effect whatsoever... Is this a bug or I am missing something?</p>
  
  <p>TIA</p>