title: socket.recv() in python truncating output on newline?
body: <h2>Bottom-Line</h2>
  <ul>
  <li>The script does not print everything from socket.recv() to the linux terminal.</li>
  <li>If I do the same thing in the interpreter, it prints all the data to the terminal.</li>
  </ul>
  <p>(let's say i use local gateway for ip and 23 for port, so telnetting into my router)</p>
  <pre><code>import socket
  q = socket.socket()
  q.connect(ip, port)
  data = q.recv(1024)
  print data
  </code></pre>
  <h2>Output in interpreter is four lines:</h2>
  <p>
  (some alt-code gibberish or whatever on the first line)<br />
  RT v24-sp2 std (c) 2012 NewMedia-NET GmbH<br />
  Release: 03/21/12 (SVN revision: 18795)<br />
  DD-WRT login:
  </p>
  <h2>Output from script:</h2>
  <p>(just the alt-code gibberish from the first line)</p>
  <p>Any advice regarding why this is happening and how to correct it would be greatly appreciated.</p>
  <p>Thanks,</p>
  <p>Andrew</p>