lldb TOT is dropping the last entry for multi-line IOHandlers that use the IOHandlerDelegateMultiline.

<rdar://problem/16844164>

llvm-svn: 208336
diff --git a/lldb/source/Core/IOHandler.cpp b/lldb/source/Core/IOHandler.cpp
index 88c96fb..8573a1a 100644
--- a/lldb/source/Core/IOHandler.cpp
+++ b/lldb/source/Core/IOHandler.cpp
@@ -529,6 +529,7 @@
     else
     {
         LineStatus lines_status = LineStatus::Success;
+        Error error;
 
         while (lines_status == LineStatus::Success)
         {
@@ -551,7 +552,6 @@
                 else
                 {
                     lines.AppendString(line);
-                    Error error;
                     lines_status = m_delegate.IOHandlerLinesUpdated(*this, lines, lines.GetSize() - 1, error);
                 }
             }
@@ -560,6 +560,11 @@
                 lines_status = LineStatus::Done;
             }
         }
+        
+        // Call the IOHandlerLinesUpdated function with UINT32_MAX as the line
+        // number to indicate all lines are complete
+        m_delegate.IOHandlerLinesUpdated(*this, lines, UINT32_MAX, error);
+
         success = lines.GetSize() > 0;
     }
     return success;