From 90a5e9389633055e9359b8099ddd0132eb86933b Mon Sep 17 00:00:00 2001 From: Ben Noordhuis Date: Wed, 29 Jan 2020 13:12:15 +0100 Subject: [PATCH] dns: default to verbatim=true in dns.lookup() Switch the default from false (reorder the result so that IPv4 addresses come before IPv6 addresses) to true (return them exactly as the resolver sent them to us.) Fixes: https://github.com/nodejs/node/issues/31566 Refs: https://github.com/nodejs/node/issues/6307 Refs: https://github.com/nodejs/node/pull/20710 Reissue of https://github.com/nodejs/node/pull/31567 Reissue of https://github.com/nodejs/node/pull/37681 --- doc/api/dns.md | 7 ++++--- lib/dns.js | 4 ++-- lib/internal/dns/promises.js | 4 ++-- test/sequential/test-net-better-error-messages-port.js | 2 +- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/doc/api/dns.md b/doc/api/dns.md index cdb948309f173f..868a5039bf237e 100644 --- a/doc/api/dns.md +++ b/doc/api/dns.md @@ -163,6 +163,9 @@ section if a custom port is used.