*
* Connection Manager
*
- * Copyright (C) 2007-2010 Intel Corporation. All rights reserved.
+ * Copyright (C) 2007-2012 Intel Corporation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
DBG("new network %s", station_name);
nw = connman_network_create(station_name,
CONNMAN_NETWORK_TYPE_WIMAX);
+ connman_network_register(nw);
connman_network_set_index(nw, connman_device_get_index(dev));
connman_network_set_name(nw, station_name);
connman_network_set_blob(nw, "WiMAX.NSP.name",
group[3 * cnt + 1] = 0;
connman_network_set_group(nw, station_name);
if (connman_device_add_network(dev, nw) < 0) {
+ connman_network_unregister(nw);
connman_network_unref(nw);
goto error_add;
}
DBG("disconnected from network %s\n",
connman_network_get_identifier(nw));
connman_network_set_connected(nw, FALSE);
+ connman_network_unregister(nw);
connman_network_unref(nw);
wmxsdk->nw = NULL;
} else