From: David Reiss Date: Fri, 24 Aug 2007 00:19:12 +0000 (+0000) Subject: Thrift: TMemoryBuffer::getAppendBufferToString fix. X-Git-Tag: 0.2.0~1250 X-Git-Url: https://source.supwisdom.com/gerrit/gitweb?a=commitdiff_plain;h=3f808ab33787044e149fb25d1c6c6c18811afde9;p=common%2Fthrift.git Thrift: TMemoryBuffer::getAppendBufferToString fix. Summary: Same fix as getBufferAsString Blame Rev: 55988 Reviewed By: dreiss Test Plan: Thrift compiles. Revert Plan: ok git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665222 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/lib/cpp/src/transport/TTransportUtils.h b/lib/cpp/src/transport/TTransportUtils.h index 518969fa..1a409752 100644 --- a/lib/cpp/src/transport/TTransportUtils.h +++ b/lib/cpp/src/transport/TTransportUtils.h @@ -326,7 +326,7 @@ class TMemoryBuffer : public TTransport { if (buffer_ == NULL) { return; } - str.append((char*)buffer_, bufferSize_); + str.append((char*)buffer_, wPos_); } void resetBuffer() {