Older Babel keeps a BigInt literal's source digits, which may carry a
0x/0o/0b prefix, so a hexadecimal zero read as truthy and a falsy socket host
such as 0x0n could drop a valid acquisition. Parse the value with BigInt.
Refs #10002
Co-Authored-By: gensokyo-dev <342580529+gensokyo-dev@users.noreply.github.com>
net and tls connect through options.host || "localhost" and throw
ERR_INVALID_ARG_TYPE from the call when that is not a string, so a truthy
non-string host leaves no socket. Read the final host, path and TLS socket
members through one option reader shared with the TLS protocol-version
check, and drop the acquisition only when the host is statically truthy and
not a string while no truthy path or TLS socket, or an Object.prototype
write that may supply one, skips the host read.
The truthy and falsy host tests come from #9380. Its intrinsic-prototype
gating changes are not included.
Fixes#10002
Co-Authored-By: 吴佳浩 <wujiahao@supremind.com>
Co-Authored-By: gensokyo-dev <342580529+gensokyo-dev@users.noreply.github.com>