Comparison

net/server_epoll.lua @ 7604:36408ef6c8c9

net.server_epoll: Call ondetach when listeners are replaced
author Kim Alvefur <zash@zash.se>
date Thu, 18 Aug 2016 17:23:06 +0200
parent 7603:4e2b019ff176
child 7606:f40f1d9b7872
comparison
equal deleted inserted replaced
7603:4e2b019ff176 7604:36408ef6c8c9
125 end 125 end
126 return ("%s FD %d"):format(tostring(self.conn), self:getfd()); 126 return ("%s FD %d"):format(tostring(self.conn), self:getfd());
127 end 127 end
128 128
129 function interface:setlistener(listeners) 129 function interface:setlistener(listeners)
130 self:on("detach");
130 self.listeners = listeners; 131 self.listeners = listeners;
131 end 132 end
132 133
133 -- Call callback 134 -- Call callback
134 function interface:on(what, ...) 135 function interface:on(what, ...)