summaryrefslogtreecommitdiffstats
path: root/contrib/Socket.h
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/Socket.h')
-rw-r--r--contrib/Socket.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/contrib/Socket.h b/contrib/Socket.h
index c3c37e1..b9f6317 100644
--- a/contrib/Socket.h
+++ b/contrib/Socket.h
@@ -50,7 +50,7 @@
namespace Socket {
struct InetAddress {
- struct sockaddr_storage addr;
+ struct sockaddr_storage addr = {};
struct sockaddr *as_sockaddr() { return reinterpret_cast<sockaddr*>(&addr); };
@@ -258,7 +258,7 @@ class TCPDataDispatcher
size_t m_max_queue_size;
- std::atomic<bool> m_running;
+ std::atomic<bool> m_running = ATOMIC_VAR_INIT(false);
std::string m_exception_data;
std::thread m_listener_thread;
TCPSocket m_listener_socket;
@@ -285,7 +285,7 @@ class TCPReceiveServer {
size_t m_blocksize = 0;
ThreadsafeQueue<std::vector<uint8_t> > m_queue;
- std::atomic<bool> m_running;
+ std::atomic<bool> m_running = ATOMIC_VAR_INIT(false);
std::string m_exception_data;
std::thread m_listener_thread;
TCPSocket m_listener_socket;