summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support/raw_ostream.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Support/raw_ostream.cpp')
-rw-r--r--llvm/lib/Support/raw_ostream.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Support/raw_ostream.cpp b/llvm/lib/Support/raw_ostream.cpp
index 42e6fda97ba..23a756e4df2 100644
--- a/llvm/lib/Support/raw_ostream.cpp
+++ b/llvm/lib/Support/raw_ostream.cpp
@@ -166,7 +166,7 @@ raw_ostream &raw_ostream::write(const char *Ptr, unsigned Size) {
case 0: break;
default:
// Normally the string to emit is shorter than the buffer.
- if (Size <= unsigned(OutBufEnd-OutBufStart)) {
+ if (Size <= unsigned(OutBufEnd-OutBufCur)) {
memcpy(OutBufCur, Ptr, Size);
break;
}
OpenPOWER on IntegriCloud