ubus: add the interface name to browse reply
authorJohn Crispin <john@phrozen.org>
Mon, 16 Jan 2023 10:04:30 +0000 (11:04 +0100)
committerJohn Crispin <john@phrozen.org>
Mon, 16 Jan 2023 10:04:50 +0000 (11:04 +0100)
Signed-off-by: John Crispin <john@phrozen.org>
ubus.c

diff --git a/ubus.c b/ubus.c
index 1ff816dcc38af78fcdc44f5a6591042f0a20730f..b9ed695a3f579215633302bfbde9dea34a571060 100644 (file)
--- a/ubus.c
+++ b/ubus.c
@@ -97,6 +97,7 @@ umdns_browse(struct ubus_context *ctx, struct ubus_object *obj,
                        *local = '\0';
                c2 = blobmsg_open_table(&b, buffer);
                strncat(buffer, ".local", MAX_NAME_LEN);
+               blobmsg_add_string(&b, "iface", s->iface->name);
                cache_dump_records(&b, buffer, array);
                cache_dump_records(&b, s->entry, array);
                blobmsg_close_table(&b, c2);