summaryrefslogtreecommitdiff
path: root/src/inspsocket.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/inspsocket.cpp')
-rw-r--r--src/inspsocket.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/inspsocket.cpp b/src/inspsocket.cpp
index 684ee051d..44fe7b72b 100644
--- a/src/inspsocket.cpp
+++ b/src/inspsocket.cpp
@@ -541,3 +541,17 @@ size_t StreamSocket::getSendQSize() const
}
return ret;
}
+
+void StreamSocket::SwapInternals(StreamSocket& other)
+{
+ if (type != other.type)
+ return;
+
+ EventHandler::SwapInternals(other);
+ std::swap(closeonempty, other.closeonempty);
+ std::swap(closing, other.closing);
+ std::swap(error, other.error);
+ std::swap(iohook, other.iohook);
+ std::swap(recvq, other.recvq);
+ std::swap(sendq, other.sendq);
+}