From 05bbc0ef6f97810a5524511ff348e2486e9b1046 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: nodejs#6307 Refs: nodejs#20710 Refs: nodejs#38099 Reissue of nodejs#31567 Reissue of nodejs#37681 Reissue of nodejs#37931 --- doc/api/dns.md | 8 +++++--- lib/internal/dns/utils.js | 5 +++-- test/sequential/test-net-better-error-messages-port.js | 2 +- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/doc/api/dns.md b/doc/api/dns.md index af9bb60967e56c..2087715cbeb039 100644 --- a/doc/api/dns.md +++ b/doc/api/dns.md @@ -170,6 +170,9 @@ section if a custom port is used.