aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2009-11-22 04:08:11 +0000
committerMatthew Wild <mwild1@gmail.com>2009-11-22 04:08:11 +0000
commit0f840b5fe7bef3b3ebc9529ebb90c55f802eb43b (patch)
treeef4823c67c4e6073f77e47005d101b26625a84fb
parent26277a79500975351326541d321a8d4ad73e9e48 (diff)
downloadprosody-0f840b5fe7bef3b3ebc9529ebb90c55f802eb43b.tar.gz
prosody-0f840b5fe7bef3b3ebc9529ebb90c55f802eb43b.zip
net.server_event: Handle and ignore 'wantread' error from receive(), treat as a timeout
-rw-r--r--net/server_event.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/server_event.lua b/net/server_event.lua
index 5df764b4..82ad899f 100644
--- a/net/server_event.lua
+++ b/net/server_event.lua
@@ -552,7 +552,7 @@ do
interface.eventread = nil
return -1
end
- if err and ( "timeout" ~= err ) then
+ if err and ( err ~= "timeout" and err ~= "wantread" ) then
if "wantwrite" == err then -- need to read on write event
if not interface.eventwrite then -- register new write event if needed
interface.eventwrite = addevent( base, interface.conn, EV_WRITE, interface.writecallback, cfg.WRITE_TIMEOUT )