[llvm-commits] [llvm] r66827 - /llvm/trunk/include/llvm/Support/raw_ostream.h

Daniel Dunbar daniel at zuster.org
Thu Mar 12 15:02:46 PDT 2009


Author: ddunbar
Date: Thu Mar 12 17:02:44 2009
New Revision: 66827

URL: http://llvm.org/viewvc/llvm-project?rev=66827&view=rev
Log:
raw_ostream: unbuffered streams weren't being immediately flushed on
single character writes.

Modified:
    llvm/trunk/include/llvm/Support/raw_ostream.h

Modified: llvm/trunk/include/llvm/Support/raw_ostream.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/raw_ostream.h?rev=66827&r1=66826&r2=66827&view=diff

==============================================================================
--- llvm/trunk/include/llvm/Support/raw_ostream.h (original)
+++ llvm/trunk/include/llvm/Support/raw_ostream.h Thu Mar 12 17:02:44 2009
@@ -84,6 +84,8 @@
     if (OutBufCur >= OutBufEnd)
       flush_impl();
     *OutBufCur++ = C;
+    if (Unbuffered)
+      flush_impl();
     return *this;
   }
 
@@ -91,6 +93,8 @@
     if (OutBufCur >= OutBufEnd)
       flush_impl();
     *OutBufCur++ = C;
+    if (Unbuffered)
+      flush_impl();
     return *this;
   }
 
@@ -98,6 +102,8 @@
     if (OutBufCur >= OutBufEnd)
       flush_impl();
     *OutBufCur++ = C;
+    if (Unbuffered)
+      flush_impl();
     return *this;
   }
 





More information about the llvm-commits mailing list