Remove unused device->control value
authorMarcel Holtmann <marcel@holtmann.org>
Sat, 6 Nov 2010 19:18:29 +0000 (20:18 +0100)
committerMarcel Holtmann <marcel@holtmann.org>
Sat, 6 Nov 2010 19:18:29 +0000 (20:18 +0100)
include/device.h
src/device.c
src/inet.c

index f8bd84e..31aa92b 100644 (file)
@@ -61,7 +61,7 @@ enum connman_device_type connman_device_get_type(struct connman_device *device);
 void connman_device_set_index(struct connman_device *device, int index);
 int connman_device_get_index(struct connman_device *device);
 void connman_device_set_interface(struct connman_device *device,
-                               const char *interface, const char *control);
+                                               const char *interface);
 
 void connman_device_set_ident(struct connman_device *device,
                                                const char *ident);
index 2912917..aa1ced6 100644 (file)
@@ -44,7 +44,6 @@ struct connman_device {
        char *node;
        char *address;
        char *interface;
-       char *control;
        char *ident;
        int phyindex;
        unsigned int connections;
@@ -409,7 +408,6 @@ static void device_destruct(struct connman_element *element)
        g_free(device->node);
        g_free(device->name);
        g_free(device->address);
-       g_free(device->control);
        g_free(device->interface);
 
        g_free(device->last_network);
@@ -575,12 +573,11 @@ void __connman_device_set_phyindex(struct connman_device *device,
  * connman_device_set_interface:
  * @device: device structure
  * @interface: interface name
- * @control: control interface
  *
  * Set interface name of device
  */
 void connman_device_set_interface(struct connman_device *device,
-                               const char *interface, const char *control)
+                                               const char *interface)
 {
        g_free(device->element.devname);
        device->element.devname = g_strdup(interface);
@@ -588,9 +585,6 @@ void connman_device_set_interface(struct connman_device *device,
        g_free(device->interface);
        device->interface = g_strdup(interface);
 
-       g_free(device->control);
-       device->control = g_strdup(control);
-
        if (device->name == NULL) {
                const char *str = type2description(device->type);
                if (str != NULL && device->interface != NULL)
index fde9592..f6b8019 100644 (file)
@@ -447,7 +447,7 @@ struct connman_device *connman_inet_create_device(int index)
        enum connman_device_type type;
        struct connman_device *device;
        char *devname, *ident = NULL;
-       char *addr = NULL, *name = NULL, *node = NULL;
+       char *addr = NULL, *name = NULL;
 
        if (index < 0)
                return NULL;
@@ -506,7 +506,7 @@ struct connman_device *connman_inet_create_device(int index)
        }
 
        connman_device_set_index(device, index);
-       connman_device_set_interface(device, devname, node);
+       connman_device_set_interface(device, devname);
 
        if (ident != NULL) {
                connman_device_set_ident(device, ident);
@@ -517,7 +517,6 @@ struct connman_device *connman_inet_create_device(int index)
 
 done:
        g_free(devname);
-       g_free(node);
        free(name);
        free(addr);