mirror of
https://github.com/tribufu/node-gamedig
synced 2026-06-01 09:42:41 +00:00
fix(telnet): use socketTimeout option for connect and exec
This commit is contained in:
parent
f2dfb8134f
commit
4645738699
1 changed files with 5 additions and 3 deletions
|
|
@ -346,10 +346,12 @@ export default class Core extends EventEmitter {
|
||||||
}
|
}
|
||||||
|
|
||||||
async telnetConnect (params) {
|
async telnetConnect (params) {
|
||||||
|
const { socketTimeout, host } = this.options
|
||||||
|
|
||||||
await this.telnetClient.connect({
|
await this.telnetClient.connect({
|
||||||
timeout: 2000,
|
timeout: socketTimeout,
|
||||||
execTimeout: 2000,
|
execTimeout: socketTimeout,
|
||||||
host: this.options.host,
|
host,
|
||||||
debug: this.debugEnabled,
|
debug: this.debugEnabled,
|
||||||
...params
|
...params
|
||||||
})
|
})
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue