title: Android:Outputstream.write - issue
body: <p>I am trying to transfer file to remote bluetooth device as given below</p>
  
  <pre><code>    while (availableBytes &gt; 0 ) {
  
                   bytesRead = inStream.read(tempData,0,tempData.length);
  
                   mmOutStream.write(tempData,0,bytesRead);  
                   mmOutStream.flush();
                   availableBytes = inStream.available();
      }/* End of availableBytes */
  </code></pre>
  
  <p>While write is in progress for large file ( 500 KB), I am getting IO exception as "IOException: Connection timed out" after 12 to 15 mins. When i am sending small file which is of &lt; 100 KB, i am successful in transferring. 
  I am not closing socket while file transfer is in progress. Is there any limitation in Android that Bluetooth socket can be active only for some fixed time limit?</p>
  
  <p>Please throw your views on this</p>