From: Yu Watanabe Date: Sun, 16 Feb 2025 12:10:55 +0000 (+0900) Subject: resolve: allow to specify SD_RESOLVED_NO_SEARCH flag in ResolveRecord X-Git-Tag: v258-rc1~1289^2~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3c31cc39812bb9735a1d8bb2fc113df374d4b49f;p=thirdparty%2Fsystemd.git 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. --- 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);