Changeset

868:9e058e51ecaf

net.server: Don't call shutdown method on socket if it doesn't have one, eg. for UDP
author Matthew Wild <mwild1@gmail.com>
date Wed, 04 Mar 2009 12:44:07 +0000
parents 867:21347a87e185
children 869:09019c452709
files net/server.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/net/server.lua	Tue Mar 03 20:12:31 2009 +0000
+++ b/net/server.lua	Wed Mar 04 12:44:07 2009 +0000
@@ -333,7 +333,7 @@
                 send( socket, table_concat( bufferqueue, "", 1, bufferqueuelen ), 1, bufferlen )    -- forced send
             end
         end
-        shutdown( socket )
+        _ = shutdown and shutdown( socket )
         socket:close( )
         _sendlistlen = removesocket( _sendlist, socket, _sendlistlen )
         _socketlist[ socket ] = nil