Software /
code /
prosody
Diff
net/server_event.lua @ 5277:8585f3cc4976
net.server_event: Destroy interfaces immediately, fixes reopening of servers.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Fri, 28 Dec 2012 14:26:21 +0100 |
parent | 5276:8a207a7e52d3 |
child | 5286:0cbe57fbe2cd |
line wrap: on
line diff
--- a/net/server_event.lua Fri Dec 28 14:25:11 2012 +0100 +++ b/net/server_event.lua Fri Dec 28 14:26:21 2012 +0100 @@ -120,14 +120,8 @@ self.position = new_position or self.position return self.position; end - function interface_mt:_close() -- regs event to start self:_destroy() - local callback = function( ) - self:_destroy(); - self.eventclose = nil - return -1 - end - self.eventclose = addevent( base, nil, EV_TIMEOUT, callback, 0 ) - return true + function interface_mt:_close() + return self:_destroy(); end function interface_mt:_start_connection(plainssl) -- should be called from addclient