spotfiresoftware / spotfire-mods

Spotfire® Mods
https://spotfiresoftware.github.io/spotfire-mods/
Other
54 stars 41 forks source link

Fix new port attempt reporting and using unexpected address #134

Closed handerss-spotfire closed 9 months ago

handerss-spotfire commented 9 months ago

If the port defined is settings is already allocated then it is possible to run into the issue where the port is allocated on a different address than "127.0.0.1". It may for instance allocate the port on IPv6 loopback. Currently we report that the address is always "127.0.0.1" but it may not be since we do not explicitly specify this address when calling server.listen.

This PR explicitly adds "127.0.0.1" to the server.listen calls as well as reporting the address which is actually reported by the "listening" event.