summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2011-09-30 18:46:42 (GMT)
committerRemko Tronçon <git@el-tramo.be>2011-09-30 18:46:42 (GMT)
commit1b255f6ba90847240b92126deb5ea0174ad269b0 (patch)
tree9d56e647ebc35c0f0941d19a302b888c1185ce1c /Swiften/FileTransfer/SOCKS5BytestreamServerSession.cpp
parentaf976a75b5e1b504a340602659ef930109cd2c48 (diff)
downloadswift-contrib-1b255f6ba90847240b92126deb5ea0174ad269b0.zip
swift-contrib-1b255f6ba90847240b92126deb5ea0174ad269b0.tar.bz2
Avoid a copy when reading from a byte array.
Diffstat (limited to 'Swiften/FileTransfer/SOCKS5BytestreamServerSession.cpp')
-rw-r--r--Swiften/FileTransfer/SOCKS5BytestreamServerSession.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Swiften/FileTransfer/SOCKS5BytestreamServerSession.cpp b/Swiften/FileTransfer/SOCKS5BytestreamServerSession.cpp
index def9e33..f660fda 100644
--- a/Swiften/FileTransfer/SOCKS5BytestreamServerSession.cpp
+++ b/Swiften/FileTransfer/SOCKS5BytestreamServerSession.cpp
@@ -145,7 +145,7 @@ void SOCKS5BytestreamServerSession::process() {
void SOCKS5BytestreamServerSession::sendData() {
if (!readBytestream->isFinished()) {
try {
- SafeByteArray dataToSend = createSafeByteArray(readBytestream->read(chunkSize));
+ SafeByteArray dataToSend = createSafeByteArray(*readBytestream->read(chunkSize));
connection->write(dataToSend);
onBytesSent(dataToSend.size());
}