aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authoryorickdewid <yorick17@outlook.com>2016-10-03 13:47:22 +0200
committeryorickdewid <yorick17@outlook.com>2016-10-03 13:47:22 +0200
commitf4f6b024038a6b777507c1d6b848ae5bab2c7422 (patch)
tree5fc3f586c80ecd49a468909dbde8deccd32dfc42 /include
parent4e39b23e455e455f1878b3e68d729a1737f3e431 (diff)
downloadcrow-f4f6b024038a6b777507c1d6b848ae5bab2c7422.tar.gz
crow-f4f6b024038a6b777507c1d6b848ae5bab2c7422.zip
Set cast type without dereferencing pointer
Diffstat (limited to 'include')
-rw-r--r--include/crow/websocket.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/crow/websocket.h b/include/crow/websocket.h
index a1e8e8f..c3ec331 100644
--- a/include/crow/websocket.h
+++ b/include/crow/websocket.h
@@ -216,7 +216,7 @@ namespace crow
[this](const boost::system::error_code& ec, std::size_t bytes_transferred)
{
is_reading = false;
- remaining_length_ = ntohs(*(uint16_t*)&remaining_length_);
+ remaining_length_ = ntohs((uint16_t)remaining_length_);
#ifdef CROW_ENABLE_DEBUG
if (!ec && bytes_transferred != 2)
{