From d51d0f3a5a60679436bf7d4e1980f3a82f229848 Mon Sep 17 00:00:00 2001 From: SmallJoker Date: Mon, 27 Sep 2021 17:45:44 +0200 Subject: Various code improvements * Camera: Fix division by 0 after view bobbing * Remove ignored constness * Connection: Improve window size range limits --- src/network/networkpacket.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/network/networkpacket.h') diff --git a/src/network/networkpacket.h b/src/network/networkpacket.h index b1c44f055..b9c39f332 100644 --- a/src/network/networkpacket.h +++ b/src/network/networkpacket.h @@ -41,7 +41,7 @@ public: u32 getSize() const { return m_datasize; } session_t getPeerId() const { return m_peer_id; } u16 getCommand() { return m_command; } - const u32 getRemainingBytes() const { return m_datasize - m_read_offset; } + u32 getRemainingBytes() const { return m_datasize - m_read_offset; } const char *getRemainingString() { return getString(m_read_offset); } // Returns a c-string without copying. -- cgit v1.2.3