-
Notifications
You must be signed in to change notification settings - Fork 30.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
src: return UV_EAI_NODATA on empty lookup #4715
Conversation
AfterGetAddrInfo() can potentially return an empty array of results without setting an error value. The JavaScript layer expects the array to have at least one value if an error is not returned. This commit sets a UV_EAI_NODATA error when an empty result array is detected. Fixes: nodejs#4545
LGTM if it works |
@allthetime can you possibly verify? |
LGTM |
CI: https://ci.nodejs.org/job/node-test-pull-request/1282/ Jenkins issues. Second run: https://ci.nodejs.org/job/node-test-pull-request/1290/ |
LGTM |
AfterGetAddrInfo() can potentially return an empty array of results without setting an error value. The JavaScript layer expects the array to have at least one value if an error is not returned. This commit sets a UV_EAI_NODATA error when an empty result array is detected. Fixes: #4545 PR-URL: #4715 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
CI is all green. Thanks for the reviews! Landed in 8bad519. |
This is fine, but would it be possible to also get a test case added to go along with this? |
I'd be happy to, but haven't been able to reproduce. I had to force |
yep, understood. |
AfterGetAddrInfo() can potentially return an empty array of results without setting an error value. The JavaScript layer expects the array to have at least one value if an error is not returned. This commit sets a UV_EAI_NODATA error when an empty result array is detected. Fixes: #4545 PR-URL: #4715 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
Is this something we might want for lts? |
SGTM |
+1 for lts |
AfterGetAddrInfo() can potentially return an empty array of results without setting an error value. The JavaScript layer expects the array to have at least one value if an error is not returned. This commit sets a UV_EAI_NODATA error when an empty result array is detected. Fixes: #4545 PR-URL: #4715 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
AfterGetAddrInfo() can potentially return an empty array of results without setting an error value. The JavaScript layer expects the array to have at least one value if an error is not returned. This commit sets a UV_EAI_NODATA error when an empty result array is detected. Fixes: #4545 PR-URL: #4715 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
AfterGetAddrInfo() can potentially return an empty array of results without setting an error value. The JavaScript layer expects the array to have at least one value if an error is not returned. This commit sets a UV_EAI_NODATA error when an empty result array is detected. Fixes: nodejs#4545 PR-URL: nodejs#4715 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
AfterGetAddrInfo()
can potentially return an empty array of results without setting an error value. The JavaScript layer expects the array to have at least one value if an error is not returned. This commit sets aUV_EAI_NODATA
error when an empty result array is detected.Fixes: #4545
R= @evanlucas