Merge branch 'development' into LTS_development

This commit is contained in:
Thulinma 2019-08-06 14:41:57 +02:00
commit 4aeb89a64f

View file

@ -1107,13 +1107,17 @@ Socket::Connection::Connection(const Connection& rhs){
up = rhs.up; up = rhs.up;
down = rhs.down; down = rhs.down;
downbuffer = rhs.downbuffer; downbuffer = rhs.downbuffer;
#ifdef SSL
if (!rhs.sslConnected){ if (!rhs.sslConnected){
#endif
if (rhs.sSend >= 0){sSend = dup(rhs.sSend);} if (rhs.sSend >= 0){sSend = dup(rhs.sSend);}
if (rhs.sRecv >= 0){sRecv = dup(rhs.sRecv);} if (rhs.sRecv >= 0){sRecv = dup(rhs.sRecv);}
#if DEBUG >= DLVL_DEVEL #if DEBUG >= DLVL_DEVEL
INFO_MSG("Socket original = (%d / %d), copy = (%d / %d)", rhs.sSend, rhs.sRecv, sSend, sRecv); INFO_MSG("Socket original = (%d / %d), copy = (%d / %d)", rhs.sSend, rhs.sRecv, sSend, sRecv);
#endif #endif
#ifdef SSL
} }
#endif
} }
//Assignment constructor //Assignment constructor
@ -1132,13 +1136,17 @@ Socket::Connection& Socket::Connection::operator=(const Socket::Connection& rhs)
up = rhs.up; up = rhs.up;
down = rhs.down; down = rhs.down;
downbuffer = rhs.downbuffer; downbuffer = rhs.downbuffer;
#ifdef SSL
if (!rhs.sslConnected){ if (!rhs.sslConnected){
#endif
if (rhs.sSend >= 0){sSend = dup(rhs.sSend);} if (rhs.sSend >= 0){sSend = dup(rhs.sSend);}
if (rhs.sRecv >= 0){sRecv = dup(rhs.sRecv);} if (rhs.sRecv >= 0){sRecv = dup(rhs.sRecv);}
#if DEBUG >= DLVL_DEVEL #if DEBUG >= DLVL_DEVEL
INFO_MSG("Socket original = (%d / %d), copy = (%d / %d)", rhs.sSend, rhs.sRecv, sSend, sRecv); INFO_MSG("Socket original = (%d / %d), copy = (%d / %d)", rhs.sSend, rhs.sRecv, sSend, sRecv);
#endif #endif
#ifdef SSL
} }
#endif
return *this; return *this;
} }