dns: handle array holes in setServers()
This commit adds better handling of exceptional array formats passed to dns.setServers(). Prior to this commit, the input array was validated using map(), which preserves holes, allowing them to be passed to c-ares, crashing Node. This commit replaces map() with forEach(), which skips holes. Fixes: https://github.com/nodejs/node/issues/8538 PR-URL: https://github.com/nodejs/node/pull/8567 Reviewed-By:Ilkka Myller <ilkka.myller@nodefield.com> Reviewed-By:
Luigi Pinca <luigipinca@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
parent
d4bf5cac
Please register or sign in to comment