Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
src: remove ParseIP() in cares_wrap.cc
This function is only used in one place where the result argument is never nullptr, so remove special handling of that case. Also, instead of returning magic values 0/4/6 and then later translating those into error/AF_INET/AF_INET6, use AF_INET/AF_INET6 directly. Lastly, inline the function, which is simpler overall. PR-URL: #44771 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Minwoo Jung <nodecorelab@gmail.com>
- Loading branch information