mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-21 16:18:29 -04:00
AP_Scripting: prevent double close in web server
This commit is contained in:
parent
7b36adf49d
commit
5d789f46ea
@ -913,7 +913,10 @@ local function Client(_sock, _idx)
|
||||
|
||||
function self.remove()
|
||||
DEBUG(string.format("%u: removing client OFFSET=%u", idx, offset))
|
||||
sock:close()
|
||||
if sock then
|
||||
sock:close()
|
||||
sock = nil
|
||||
end
|
||||
self.closed = true
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user