Skip to content

Commit

Permalink
dns: use ARES_LIB_INIT_NONE instead of a magic number
Browse files Browse the repository at this point in the history
the parameter passed to `ares_library_init()` is a bitmap. so 0
is indeed nothing but `ARES_LIB_INIT_NONE` is more readable.

Signed-off-by: Kefu Chai <kefu.chai@scylladb.com>
  • Loading branch information
tchaikov committed Oct 9, 2024
1 parent 7139445 commit 4ed89dd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/net/dns.cc
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ static void check_ares_error(int error) {

struct ares_initializer {
ares_initializer() {
check_ares_error(ares_library_init(0));
check_ares_error(ares_library_init(ARES_LIB_INIT_NONE));
}
~ares_initializer() {
ares_library_cleanup();
Expand Down

0 comments on commit 4ed89dd

Please sign in to comment.