Don't allow having two node modules use the same socket
This commit is contained in:
parent
3abb296109
commit
37c983ce0b
@ -52,9 +52,6 @@ export default class ClientManager {
|
|||||||
} catch (err) {
|
} catch (err) {
|
||||||
await fs.promises.mkdir(path.dirname(socketPath), 0o700)
|
await fs.promises.mkdir(path.dirname(socketPath), 0o700)
|
||||||
}
|
}
|
||||||
try {
|
|
||||||
await fs.promises.unlink(socketPath)
|
|
||||||
} catch (err) {}
|
|
||||||
await promisify(cb => this.server.listen(socketPath, cb))
|
await promisify(cb => this.server.listen(socketPath, cb))
|
||||||
await fs.promises.chmod(socketPath, 0o700)
|
await fs.promises.chmod(socketPath, 0o700)
|
||||||
this.log("Now listening at", socketPath)
|
this.log("Now listening at", socketPath)
|
||||||
|
Loading…
Reference in New Issue
Block a user