I'm building and application that uses many sockets, in some cases, two socket.io servers try to start with the same tcp port (this is expected actually), so one of them crashes with Error: EADDRINUSE.
What I want is to "catch" the error and then do something about it. I mean, the error in some cases is expected, but I want to handle it properly. I can't find a way to do it.
Thanks!