Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto-port calling listen callback N times where N is the amount of port attempts #1

Open
Marak opened this issue Nov 29, 2014 · 0 comments
Labels

Comments

@Marak
Copy link
Member

Marak commented Nov 29, 2014

There is an issue with the auto-port functionality which causes the callback handler for http.listen to be called N times, where N is the attempts at auto-porting.

The core issue is that either Node itself or Express won't pass EADDRINUSE errors through the normal error object in listen callback. The only way to catch this error is to listen for server.on("error").

Work around requires minor refactor of auto-port logic.

@Marak Marak added the bug label Nov 29, 2014
Marak added a commit that referenced this issue Sep 22, 2015
 * No longer calling callback multiple times
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant