Files
node/lib/internal
Sagi Tsofan 82ea7058b6 lib: http server, friendly error messages
Improved error message description for the http server binding errors.

Currently changed only in `setupListenHandle`, but needs to be
change all over.

Added new `uvExceptionWithHostPort` function (+export) in
`lib/internal/error.js` that extracts the error message defined by
libuv, using the error code, and returns an error object with the
full error description.

example:
old error message: `listen EADDRINUSE`
new error message: `listen EADDRINUSE: Address already in use`

Removed exportable function `_exceptionWithHostPort` from
`lib/util.js` - exported by accident

Replaced `exceptionWithHostPort` to the new function
`uvExceptionWithHostPort` for a more detailed error.

Fixes: https://github.com/nodejs/node/issues/22936

PR-URL: https://github.com/nodejs/node/pull/22995
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-10-11 21:21:36 -07:00
..
2018-10-06 17:33:25 -05:00
2018-10-06 17:33:25 -05:00
2018-07-14 14:04:38 +02:00
2018-05-18 15:25:41 +02:00
2018-09-11 16:58:16 +08:00
2018-09-18 17:10:40 -05:00
2018-02-16 18:09:56 +01:00
2018-08-12 10:44:53 -07:00
2018-05-18 15:25:41 +02:00

Internal Modules

The modules in lib/internal are intended for internal use in Node.js core only, and are not accessible with require() from user modules. These modules can be changed at any time. Reliance on these modules outside of core is not supported in any way.