mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-03-09 15:40:18 +00:00
Added IPKVM timeout handling.
This commit is contained in:
parent
bd915de7fc
commit
cfeab35332
1 changed files with 6 additions and 3 deletions
|
@ -318,7 +318,8 @@ function CreateRaritanKX3Manager(parent, hostname, port, username, password) {
|
||||||
res.on('data', function (d) { })
|
res.on('data', function (d) { })
|
||||||
fetchInitialInformation();
|
fetchInitialInformation();
|
||||||
})
|
})
|
||||||
req.on('error', function (error) { setState(0); })
|
req.on('error', function (error) { setState(0); });
|
||||||
|
req.on('timeout', function () { setState(0); });
|
||||||
req.write(data);
|
req.write(data);
|
||||||
req.end();
|
req.end();
|
||||||
}
|
}
|
||||||
|
@ -343,7 +344,8 @@ function CreateRaritanKX3Manager(parent, hostname, port, username, password) {
|
||||||
if (res.headers['set-cookie'] != null) { for (var i in res.headers['set-cookie']) { if (res.headers['set-cookie'][i].startsWith('pp_session_id=')) { obj.authCookie = res.headers['set-cookie'][i].substring(14).split(';')[0]; } } }
|
if (res.headers['set-cookie'] != null) { for (var i in res.headers['set-cookie']) { if (res.headers['set-cookie'][i].startsWith('pp_session_id=')) { obj.authCookie = res.headers['set-cookie'][i].substring(14).split(';')[0]; } } }
|
||||||
res.on('data', function (d) { })
|
res.on('data', function (d) { })
|
||||||
});
|
});
|
||||||
req.on('error', function (error) { setState(0); })
|
req.on('error', function (error) { setState(0); });
|
||||||
|
req.on('timeout', function () { setState(0); });
|
||||||
req.end();
|
req.end();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -508,7 +510,8 @@ function CreateRaritanKX3Manager(parent, hostname, port, username, password) {
|
||||||
func(obj, tag, Buffer.concat(data), res);
|
func(obj, tag, Buffer.concat(data), res);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
req.on('error', function (error) { console.log(error); setState(0); })
|
req.on('error', function (error) { setState(0); });
|
||||||
|
req.on('timeout', function () { setState(0); });
|
||||||
req.end();
|
req.end();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue