Skip to content

Commit

Permalink
Remove unnecessary std::move
Browse files Browse the repository at this point in the history
onFrameDataRead accepts a const reference, so no move will happen.
  • Loading branch information
syyyr committed Feb 19, 2024
1 parent db12a88 commit 9eaa6e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libshvchainpack/src/chainpack/socketrpcdriver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ void SocketRpcDriver::exec()
if (m_readFrameSize > 0 && m_readFrameSize <= m_readBuffer.size()) {
auto frame = std::string(m_readBuffer, 0, m_readFrameSize);
m_readBuffer = std::string(m_readBuffer, m_readFrameSize);
onFrameDataRead(std::move(frame));
onFrameDataRead(frame);
}
if (m_readFrameSize == 0 || m_readFrameSize > m_readBuffer.size()) {
break;
Expand Down

0 comments on commit 9eaa6e1

Please sign in to comment.