exec_cmd(task, "DISABLE_NETWORK 0");
+ if (network == NULL)
+ return 0;
+
sprintf(cmd, "SET_NETWORK 0 ssid \"%s\"", network);
exec_cmd(task, cmd);
return 0;
}
+
+int __supplicant_disconnect(struct connman_iface *iface)
+{
+ struct supplicant_task *task;
+
+ task = find_task(iface->index);
+ if (task == NULL)
+ return -ENODEV;
+
+ printf("[SUPPLICANT] disconnect %s\n", task->ifname);
+
+ exec_cmd(task, "DISABLE_NETWORK 0");
+
+ return 0;
+}
int __supplicant_connect(struct connman_iface *iface,
const char *network, const char *passphrase);
+int __supplicant_disconnect(struct connman_iface *iface);