Don't re-enable configuration if already set
authorMarcel Holtmann <marcel@holtmann.org>
Tue, 5 Jan 2010 00:35:49 +0000 (16:35 -0800)
committerMarcel Holtmann <marcel@holtmann.org>
Tue, 5 Jan 2010 00:35:49 +0000 (16:35 -0800)
src/ipconfig.c

index 07fa770..df708bb 100644 (file)
@@ -895,6 +895,9 @@ int __connman_ipconfig_enable(struct connman_ipconfig *ipconfig)
        if (ipdevice == NULL)
                return -ENXIO;
 
+       if (ipdevice->config == ipconfig)
+               return -EALREADY;
+
        if (ipdevice->config != NULL) {
                ipconfig_list = g_list_remove(ipconfig_list, ipconfig);