diff options
author | Daniel Golle <daniel@makrotopia.org> | 2020-04-06 23:58:40 +0100 |
---|---|---|
committer | Daniel Golle <daniel@makrotopia.org> | 2020-04-14 00:22:21 +0100 |
commit | f37d6342367b4f8393f9693edd96b12dfa016399 (patch) | |
tree | 39814f5b920a29263d3d25bd9991a4e906297b8b /package/network/services/hostapd/src/wpa_supplicant | |
parent | 35f208da3c13cc16227f229f8aea14c4f0a06928 (diff) | |
download | upstream-f37d6342367b4f8393f9693edd96b12dfa016399.tar.gz upstream-f37d6342367b4f8393f9693edd96b12dfa016399.tar.bz2 upstream-f37d6342367b4f8393f9693edd96b12dfa016399.zip |
hostapd: reduce to a single instance per service
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Diffstat (limited to 'package/network/services/hostapd/src/wpa_supplicant')
-rw-r--r-- | package/network/services/hostapd/src/wpa_supplicant/ubus.c | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/package/network/services/hostapd/src/wpa_supplicant/ubus.c b/package/network/services/hostapd/src/wpa_supplicant/ubus.c index 5450b24476..4bb92a7b66 100644 --- a/package/network/services/hostapd/src/wpa_supplicant/ubus.c +++ b/package/network/services/hostapd/src/wpa_supplicant/ubus.c @@ -322,27 +322,12 @@ static struct ubus_object_type wpas_daemon_object_type = void wpas_ubus_add(struct wpa_global *global) { struct ubus_object *obj = &global->ubus_global; - char *name; - int name_len; int ret; if (!wpas_ubus_init()) return; - name_len = strlen("wpa_supplicant") + 1; - if (global->params.name) - name_len += strlen(global->params.name) + 1; - - name = malloc(name_len); - strcpy(name, "wpa_supplicant"); - - if (global->params.name) - { - strcat(name, "."); - strcat(name, global->params.name); - } - - obj->name = name; + obj->name = strdup("wpa_supplicant"); obj->type = &wpas_daemon_object_type; obj->methods = wpas_daemon_object_type.methods; |