diff options
author | Liang Qi <liang.qi@theqtcompany.com> | 2015-09-11 09:58:50 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@theqtcompany.com> | 2015-09-14 14:30:35 +0000 |
commit | f11862a05591452bdad9c1abd244288a2964a036 (patch) | |
tree | 7e18dede3ecf0dfa6a9797dceee4367c3aee4de0 /src/websockets/qwebsocketframe_p.h | |
parent | c5f63b60330c05a5b70d5f5f42565f32227f161b (diff) | |
download | qtwebsockets-f11862a05591452bdad9c1abd244288a2964a036.tar.gz |
rsv1-3 should be bool instead of int
And reorded the data members of QWebSocketFrame to save some space.
Change-Id: I6fdaf74f344ac84e5a3f19883309455503a7ec4c
Reviewed-by: Luca Niccoli <lultimouomo@gmail.com>
Reviewed-by: Maks Naumov <maksqwe1@ukr.net>
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Diffstat (limited to 'src/websockets/qwebsocketframe_p.h')
-rw-r--r-- | src/websockets/qwebsocketframe_p.h | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/websockets/qwebsocketframe_p.h b/src/websockets/qwebsocketframe_p.h index 131775b..b0c1ab2 100644 --- a/src/websockets/qwebsocketframe_p.h +++ b/src/websockets/qwebsocketframe_p.h @@ -75,9 +75,9 @@ public: bool isContinuationFrame() const; bool hasMask() const; quint32 mask() const; //returns 0 if no mask - int rsv1() const; - int rsv2() const; - int rsv3() const; + inline bool rsv1() const { return m_rsv1; } + inline bool rsv2() const { return m_rsv2; } + inline bool rsv3() const { return m_rsv3; } QWebSocketProtocol::OpCode opCode() const; QByteArray payload() const; @@ -90,16 +90,15 @@ public: private: QWebSocketProtocol::CloseCode m_closeCode; QString m_closeReason; - bool m_isFinalFrame; quint32 m_mask; - int m_rsv1; - int m_rsv2; - int m_rsv3; QWebSocketProtocol::OpCode m_opCode; - quint8 m_length; QByteArray m_payload; + bool m_isFinalFrame; + bool m_rsv1; + bool m_rsv2; + bool m_rsv3; bool m_isValid; enum ProcessingState |