mirror of
https://dev.iopsys.eu/bbf/icwmp.git
synced 2026-03-13 12:32:20 +01:00
Fix Device.Ethernet.Link.{i}.LastChange parameter issue
This commit is contained in:
parent
d3fa65425f
commit
424a7b4dbb
1 changed files with 4 additions and 2 deletions
|
|
@ -347,7 +347,6 @@ int addObjEthernetLink(char *refparam, struct dmctx *ctx, void *data, char **ins
|
|||
|
||||
dmuci_add_section_icwmpd(DMMAP, "link", &dmmap_network, &v);
|
||||
*instance = update_instance_icwmpd(dmmap_network, inst, "link_instance");
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -938,7 +937,10 @@ int get_EthernetLink_Name(char *refparam, struct dmctx *ctx, void *data, char *i
|
|||
int get_EthernetLink_LastChange(char *refparam, struct dmctx *ctx, void *data, char *instance, char **value)
|
||||
{
|
||||
json_object *res;
|
||||
dmubus_call("network.interface", "status", UBUS_ARGS{{"interface", section_name(((struct dm_args *)data)->section), String}}, 1, &res);
|
||||
char *interface;
|
||||
|
||||
dmuci_get_value_by_section_string(((struct dm_args *)data)->section, "section_name", &interface);
|
||||
dmubus_call("network.interface", "status", UBUS_ARGS{{"interface", interface, String}}, 1, &res);
|
||||
DM_ASSERT(res, *value = "0");
|
||||
*value = dmjson_get_value(res, 1, "uptime");
|
||||
if((*value)[0] == '\0')
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue