From 3c31cc39812bb9735a1d8bb2fc113df374d4b49f Mon Sep 17 00:00:00 2001 From: Yu Watanabe Date: Sun, 16 Feb 2025 21:10:55 +0900 Subject: [PATCH] resolve: allow to specify SD_RESOLVED_NO_SEARCH flag in ResolveRecord The varlink method io.systemd.Resolve.ResolveRecord already accepts the flag. Let's also the bus method accept the flag, for consistency. --- src/resolve/resolved-bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/resolve/resolved-bus.c b/src/resolve/resolved-bus.c index 96cfd32257a..8415444463d 100644 --- a/src/resolve/resolved-bus.c +++ b/src/resolve/resolved-bus.c @@ -796,7 +796,7 @@ static int bus_method_resolve_record(sd_bus_message *message, void *userdata, sd if (dns_type_is_obsolete(type)) return sd_bus_error_setf(error, SD_BUS_ERROR_NOT_SUPPORTED, "Specified DNS resource record type %" PRIu16 " is obsolete.", type); - if (validate_and_mangle_query_flags(m, &flags, name, /* ok = */ 0) < 0) + if (validate_and_mangle_query_flags(m, &flags, name, SD_RESOLVED_NO_SEARCH) < 0) return sd_bus_error_set(error, SD_BUS_ERROR_INVALID_ARGS, "Invalid flags parameter"); question = dns_question_new(1); -- 2.47.3