diff options
author | Frederik Gladhorn <frederik.gladhorn@digia.com> | 2014-01-17 18:20:40 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-01-18 00:20:27 +0100 |
commit | aa66bb128b4d853c6de200bf374758025dcd94b2 (patch) | |
tree | 97489863843aacc053c88c117b9203a6c30f5058 /src/websockets/qwebsocketdataprocessor_p.h | |
parent | 6c12e81e58b5e38c4d075cc6d7adaaaf01d80879 (diff) | |
download | qtwebsockets-aa66bb128b4d853c6de200bf374758025dcd94b2.tar.gz |
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 <pattyn.kurt@gmail.com>
Diffstat (limited to 'src/websockets/qwebsocketdataprocessor_p.h')
-rw-r--r-- | src/websockets/qwebsocketdataprocessor_p.h | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/websockets/qwebsocketdataprocessor_p.h b/src/websockets/qwebsocketdataprocessor_p.h index 256bcf4..983d391 100644 --- a/src/websockets/qwebsocketdataprocessor_p.h +++ b/src/websockets/qwebsocketdataprocessor_p.h @@ -78,14 +78,14 @@ public: static quint64 maxFrameSize(); Q_SIGNALS: - void pingReceived(QByteArray data); - void pongReceived(QByteArray data); - void closeReceived(QWebSocketProtocol::CloseCode closeCode, QString closeReason); - void textFrameReceived(QString frame, bool lastFrame); - void binaryFrameReceived(QByteArray frame, bool lastFrame); - void textMessageReceived(QString message); - void binaryMessageReceived(QByteArray message); - void errorEncountered(QWebSocketProtocol::CloseCode code, QString description); + void pingReceived(const QByteArray &data); + void pongReceived(const QByteArray &data); + void closeReceived(QWebSocketProtocol::CloseCode closeCode, const QString &closeReason); + void textFrameReceived(const QString &frame, bool lastFrame); + void binaryFrameReceived(const QByteArray &frame, bool lastFrame); + void textMessageReceived(const QString &message); + void binaryMessageReceived(const QByteArray &message); + void errorEncountered(QWebSocketProtocol::CloseCode code, const QString &description); public Q_SLOTS: void process(QIODevice *pIoDevice); |