summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Changelog-Trunk.txt1
-rw-r--r--src/common/socket.c4
2 files changed, 3 insertions, 2 deletions
diff --git a/Changelog-Trunk.txt b/Changelog-Trunk.txt
index 80e359c73..6ce52035e 100644
--- a/Changelog-Trunk.txt
+++ b/Changelog-Trunk.txt
@@ -4,6 +4,7 @@ AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
2006/12/13
+ * Modified flush_fifo so the code do what is written in the comment [Toms]
* Modified flush_fifo so you can decide whether to block the current thread
or not until the data is sent. The server-tick reply no longer blocks the
current thread.
diff --git a/src/common/socket.c b/src/common/socket.c
index 19a2ecdea..7ee8ac53e 100644
--- a/src/common/socket.c
+++ b/src/common/socket.c
@@ -289,9 +289,9 @@ void flush_fifo(int fd, int lock)
return;
if (lock)
{ //Lock the thread until data is sent.
- set_nonblocking(fd, 1);
- send_from_fifo(fd);
set_nonblocking(fd, 0);
+ send_from_fifo(fd);
+ set_nonblocking(fd, 1);
return;
}
//Send without locking the thread.