Do not pass the -H option to dhclient task
authorSamuel Ortiz <sameo@linux.intel.com>
Mon, 12 Jul 2010 19:05:33 +0000 (21:05 +0200)
committerSamuel Ortiz <sameo@linux.intel.com>
Mon, 12 Jul 2010 19:08:00 +0000 (21:08 +0200)
This option is only supported by RedHat's dhclient package.

configure.ac
plugins/dhclient.c

index 7b895d7..6514483 100644 (file)
@@ -128,12 +128,6 @@ if (test "${enable_dhclient}" != "no"); then
                DHCLIENT="${path_dhclient}"
                AC_SUBST(DHCLIENT)
        fi
-       AC_MSG_CHECKING(dhclient major version)
-       version_dhclient=`${DHCLIENT} --version 2>&1 | sed '/^isc-dhclient-*/!d; s///; s/\..*//;q'`
-       AC_MSG_RESULT(${version_dhclient})
-       if (test "${version_dhclient}" = "4"); then
-               AC_DEFINE(HAVE_DHCLIENT_HOSTNAME, 1, [Define to 1 if you have dhclient hostname support.])
-       fi
 fi
 AM_CONDITIONAL(DHCLIENT, test "${enable_dhclient}" != "no")
 AM_CONDITIONAL(DHCLIENT_BUILTIN, test "${enable_dhclient}" = "builtin")
index b3bcf0e..8b2af6b 100644 (file)
@@ -149,7 +149,6 @@ static void dhclient_died(struct connman_task *task, void *user_data)
 static void dhclient_setup(struct connman_task *task, const char *ifname)
 {
        const char *path, *intf = "org.moblin.connman.Task";
-       const char *hostname;
 
        path = connman_task_get_path(task);
 
@@ -164,13 +163,6 @@ static void dhclient_setup(struct connman_task *task, const char *ifname)
                                                        STATEDIR, ifname);
        connman_task_add_argument(task, "-cf", "%s/dhclient.conf", SCRIPTDIR);
        connman_task_add_argument(task, "-sf", "%s/dhclient-script", SCRIPTDIR);
-
-       hostname = connman_utsname_get_hostname();
-#ifdef HAVE_DHCLIENT_HOSTNAME
-       if (hostname != NULL)
-               connman_task_add_argument(task, "-H", hostname);
-#endif
-
        connman_task_add_argument(task, ifname, NULL);
        connman_task_add_argument(task, "-n", NULL);
 }