remove configuration option 'plat_from_dns64_hostname'
am: b6b5104bab

Change-Id: I6d48e97a03d770d95824c59151e9ef54e5bb037d
diff --git a/clatd.conf b/clatd.conf
index ff80975..aef9c75 100644
--- a/clatd.conf
+++ b/clatd.conf
@@ -14,8 +14,6 @@
 
 # get the plat_subnet from dns lookups (requires DNS64)
 plat_from_dns64 yes
-# hostname to use to lookup plat subnet. must contain only A records
-plat_from_dns64_hostname ipv4only.arpa
 
 # plat subnet to send ipv4 traffic to. This is a /96 subnet.
 # This setting only makes sense with: plat_from_dns64 no
diff --git a/config.c b/config.c
index a859092..3ea510d 100644
--- a/config.c
+++ b/config.c
@@ -150,16 +150,6 @@
   return ret_val_ptr;
 }
 
-/* function: free_config
- * frees the memory used by the global config variable
- */
-void free_config() {
-  if (Global_Clatd_Config.plat_from_dns64_hostname) {
-    free(Global_Clatd_Config.plat_from_dns64_hostname);
-    Global_Clatd_Config.plat_from_dns64_hostname = NULL;
-  }
-}
-
 /* function: ipv6_prefix_equal
  * compares the prefixes two ipv6 addresses. assumes the prefix lengths are both /64.
  *   a1 - first address
@@ -180,7 +170,7 @@
   backoff_sleep = 1;
 
   while (1) {
-    status = plat_prefix(Global_Clatd_Config.plat_from_dns64_hostname, net_id, &tmp_ptr);
+    status = plat_prefix(DNS64_DETECTION_HOSTNAME, net_id, &tmp_ptr);
     if (status > 0) {
       memcpy(&Global_Clatd_Config.plat_subnet, &tmp_ptr, sizeof(struct in6_addr));
       return;
@@ -357,9 +347,6 @@
     } else {
       free(tmp_ptr);
 
-      if (!(Global_Clatd_Config.plat_from_dns64_hostname =
-              config_item_str(root, "plat_from_dns64_hostname", DEFAULT_DNS64_DETECTION_HOSTNAME)))
-        goto failed;
       dns64_detection(net_id);
     }
   }
@@ -381,7 +368,6 @@
 
 failed:
   free(root);
-  free_config();
   return 0;
 }
 
diff --git a/config.h b/config.h
index e521b74..88c632a 100644
--- a/config.h
+++ b/config.h
@@ -23,7 +23,7 @@
 
 #define DEFAULT_IPV4_LOCAL_SUBNET "192.0.0.4"
 #define DEFAULT_IPV4_LOCAL_PREFIXLEN "29"
-#define DEFAULT_DNS64_DETECTION_HOSTNAME "ipv4only.arpa"
+#define DNS64_DETECTION_HOSTNAME "ipv4only.arpa"
 
 struct clat_config {
   int16_t mtu, ipv4mtu;
@@ -33,7 +33,6 @@
   int16_t ipv4_local_prefixlen;
   struct in6_addr plat_subnet;
   char *default_pdp_interface;
-  char *plat_from_dns64_hostname;
   int use_dynamic_iid;
 };