-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
fix use of deprecated c-ares api #15837
Conversation
ares_process(...) has been deprecated. Replace it with ares_process_fd(...) Signed-off-by: Andrew Cooks <acooks.at.bda@gmail.com>
Somewhat similar theme as #14869 I'm not sure how to make this backwards compatible with older versions of c-ares, |
You need to put a bit in the configure.ac file that detects c-ares versioning, see usage of AC_CHECK_LIB examples in the file. If you are not sure how to do that respond here and we can work with you. |
5839f52
to
49ffbab
Compare
c-ares has deprecated ares_gethostbyname() in version 1.28.0 Replace it with ares_getaddrinfo(). This fixes a build error on Fedora 40. Signed-off-by: Andrew Cooks <acooks.at.bda@gmail.com>
49ffbab
to
89a2e4d
Compare
Thanks. I saw how to add a version dependency in configure.ac. Perhaps I misunderstood your suggestion, but in this case I think both old and new versions of c-ares would need to be supported. Luckily c-ares provides a ARES_VERSION macro in ares_version.h, which is already included. |
ci:rerun |
@Mergifyio backport stable/10.0 |
✅ Backports have been created
|
fix use of deprecated c-ares api (backport #15837)
@Mergifyio backport stable/9.1 stable/9.0 stable/8.5 |
✅ Backports have been created
|
fix use of deprecated c-ares api (backport #15837)
fix use of deprecated c-ares api (backport #15837)
The c-ares api has deprecated ares_process() and ares_gethostbyname() and it causes a build failure on Fedora 40.
This PR replaces the deprecated functions with their replacements.