Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
blocktrron committed Apr 19, 2024
1 parent e6c8d64 commit f0c542b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/interface.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,10 @@ int nw_interface_update(struct ubus_context *ctx, char *vendor_elements)
blob_buf_init(&b, 0);
blobmsg_add_string(&b, "vendor_elements", vendor_elements);

if (!nw_interface_enabled(instance, iface->ubus.name)) {
continue;
}

log_debug("Sending vendor elements to id=%d name=%s", iface->ubus.id, iface->ubus.name);
ret = ubus_invoke(ctx, iface->ubus.id, "set_vendor_elements", b.head, NULL, NULL, 1000);
if (ret) {
Expand All @@ -69,10 +73,6 @@ int nw_interface_update(struct ubus_context *ctx, char *vendor_elements)
/* Delete element */
blob_buf_init(&b, 0);
blobmsg_add_string(&b, "vendor_elements", "");

if (!nw_interface_enabled(instance, iface->ubus.name)) {
continue;
}

ret = ubus_invoke(ctx, iface->ubus.id, "set_vendor_elements", b.head, NULL, NULL, 1000);
if (ret) {
Expand Down

0 comments on commit f0c542b

Please sign in to comment.