From e008ee04b20d6ba25d16a890443263bb7f10f609 Mon Sep 17 00:00:00 2001 From: Rolf Ahrenberg Date: Sun, 19 Nov 2017 15:25:31 +0200 Subject: [PATCH] Strip off the constructor delegation after all to broaden compiler compability. --- README | 2 +- socket.c | 10 +++++++++- socket.h | 3 ++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/README b/README index b247375..9c8f9be 100644 --- a/README +++ b/README @@ -171,7 +171,7 @@ Notes: parameters: $ cat /proc/sys/net/core/rmem_default $ cat /proc/sys/net/core/rmem_max - + Acknowledgements: - Big thanks to Digital Devices GmbH for providing the Octopus Net diff --git a/socket.c b/socket.c index 7ea436b..b51d6ea 100644 --- a/socket.c +++ b/socket.c @@ -28,8 +28,16 @@ #endif cSatipSocket::cSatipSocket() -: cSatipSocket(0) +: socketPortM(0), + socketDescM(-1), + isMulticastM(false), + useSsmM(false), + streamAddrM(htonl(INADDR_ANY)), + sourceAddrM(htonl(INADDR_ANY)), + rcvBufSizeM(0) { + debug1("%s", __PRETTY_FUNCTION__); + memset(&sockAddrM, 0, sizeof(sockAddrM)); } cSatipSocket::cSatipSocket(size_t rcvBufSizeP) diff --git a/socket.h b/socket.h index cd4b75d..289f96c 100644 --- a/socket.h +++ b/socket.h @@ -20,13 +20,14 @@ private: in_addr_t streamAddrM; in_addr_t sourceAddrM; size_t rcvBufSizeM; + bool CheckAddress(const char *addrP, in_addr_t *inAddrP); bool Join(void); bool Leave(void); public: cSatipSocket(); - cSatipSocket(size_t rcvBufSizeP); + explicit cSatipSocket(size_t rcvBufSizeP); virtual ~cSatipSocket(); bool Open(const int portP = 0, const bool reuseP = false); bool OpenMulticast(const int portP, const char *streamAddrP, const char *sourceAddrP);