From aa66bb128b4d853c6de200bf374758025dcd94b2 Mon Sep 17 00:00:00 2001 From: Frederik Gladhorn Date: Fri, 17 Jan 2014 18:20:40 +0100 Subject: Add a few more const refs In case of processPing we need to make a copy that potentially detaches when masking is requested, but pings are < 125 bytes. Before this code would copy the byte array in the same way much earlier. Change-Id: If0592bb4b508eeb11fdbf05c4bb98b9679ed0549 Reviewed-by: Kurt Pattyn --- src/websockets/qwebsocketframe_p.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/websockets/qwebsocketframe_p.h') diff --git a/src/websockets/qwebsocketframe_p.h b/src/websockets/qwebsocketframe_p.h index 74597a2..8c06a27 100644 --- a/src/websockets/qwebsocketframe_p.h +++ b/src/websockets/qwebsocketframe_p.h @@ -118,7 +118,7 @@ private: PS_WAIT_FOR_MORE_DATA }; - void setError(QWebSocketProtocol::CloseCode code, QString closeReason); + void setError(QWebSocketProtocol::CloseCode code, const QString &closeReason); bool checkValidity(); }; -- cgit v1.2.1