summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2012-10-28 21:26:57 +0000
committerrubidium <rubidium@openttd.org>2012-10-28 21:26:57 +0000
commit6247bdbdb4b2972ef39b0715cb318c5af9801b79 (patch)
tree24ca548e6834e611562d2849c695a293c1585efe /src
parent9db98f3b145eea7d023700a9973a3326dfc52cff (diff)
downloadopenttd-6247bdbdb4b2972ef39b0715cb318c5af9801b79.tar.xz
(svn r24642) -Codechange: add helper function to see if there is anything in the send queue
Diffstat (limited to 'src')
-rw-r--r--src/network/core/tcp.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/network/core/tcp.h b/src/network/core/tcp.h
index 2092e1e32..e55605561 100644
--- a/src/network/core/tcp.h
+++ b/src/network/core/tcp.h
@@ -50,6 +50,12 @@ public:
bool CanSendReceive();
+ /**
+ * Whether there is something pending in the send queue.
+ * @return true when someting is pending in the send queue.
+ */
+ bool HasSendQueue() { return this->packet_queue != NULL; }
+
NetworkTCPSocketHandler(SOCKET s = INVALID_SOCKET);
~NetworkTCPSocketHandler();
};