From 31947449e30a8bc46ebf94d426ad09b9ad718b40 Mon Sep 17 00:00:00 2001 From: cjihrig Date: Thu, 7 Mar 2019 09:13:40 -0500 Subject: doc: document fake ENOTFOUND as a system error PR-URL: https://github.com/nodejs/node/pull/26495 Fixes: https://github.com/nodejs/node/issues/26484 Reviewed-By: Anna Henningsen Reviewed-By: Ruben Bridgewater Reviewed-By: Richard Lau Reviewed-By: Rich Trott Reviewed-By: James M Snell --- lib/internal/errors.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/internal/errors.js') diff --git a/lib/internal/errors.js b/lib/internal/errors.js index b3b745252a..a76153297e 100644 --- a/lib/internal/errors.js +++ b/lib/internal/errors.js @@ -432,8 +432,8 @@ function dnsException(code, syscall, hostname) { // If `code` is of type number, it is a libuv error number, else it is a // c-ares error code. if (typeof code === 'number') { - // FIXME(bnoordhuis) Remove this backwards compatibility nonsense and pass - // the true error to the user. ENOTFOUND is not even a proper POSIX error! + // ENOTFOUND is not a proper POSIX error, but this error has been in place + // long enough that it's not practical to remove it. if (code === lazyUv().UV_EAI_NODATA || code === lazyUv().UV_EAI_NONAME) { code = 'ENOTFOUND'; // Fabricated error name. } else { -- cgit v1.2.3