Thrift string copy construction pathces from kevin ko
Summary: Remove unnecessary string copy constructions in C++ code
Reviewed By: mcslee
Test Plan: build
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665084 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/lib/cpp/src/protocol/TProtocol.h b/lib/cpp/src/protocol/TProtocol.h
index 735268e..6264bb6 100644
--- a/lib/cpp/src/protocol/TProtocol.h
+++ b/lib/cpp/src/protocol/TProtocol.h
@@ -88,9 +88,9 @@
* Writing functions.
*/
- virtual uint32_t writeMessageBegin(const std::string name,
- const TMessageType messageType,
- const int32_t seqid) = 0;
+ virtual uint32_t writeMessageBegin(const std::string& name,
+ const TMessageType messageType,
+ const int32_t seqid) = 0;
virtual uint32_t writeMessageEnd() = 0;