Revert a small but important part of the EOF handling code that Greg

missed in his previous revert.

llvm-svn: 121712
This commit is contained in:
Caroline Tice
2010-12-13 20:05:03 +00:00
parent 2d434e594e
commit 01cb3ea2ee

View File

@@ -155,9 +155,13 @@ ConnectionFileDescriptor::Read (void *dst, size_t dst_len, ConnectionStatus &sta
Error error;
ssize_t bytes_read = ::read (m_fd, dst, dst_len);
if (bytes_read == 0)
// Disable the end-of-file special handling stuff for now. Hopefully re-instate it (properly fixed) at a
// later date:
{
error.Clear(); // End-of-file. Do not automatically close; pass along for the end-of-file handlers.
status = eConnectionStatusEndOfFile;
// error.Clear(); // End-of-file. Do not automatically close; pass along for the end-of-file handlers.
// status = eConnectionStatusEndOfFile;
error.SetErrorStringWithFormat("End-of-file.\n");
status = eConnectionStatusLostConnection;
}
else if (bytes_read < 0)
{