summaryrefslogtreecommitdiffstats
path: root/mdk-stage1
diff options
context:
space:
mode:
Diffstat (limited to 'mdk-stage1')
-rw-r--r--mdk-stage1/network.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/mdk-stage1/network.c b/mdk-stage1/network.c
index 5ce055c8a..19d6d3710 100644
--- a/mdk-stage1/network.c
+++ b/mdk-stage1/network.c
@@ -240,7 +240,8 @@ static int add_default_route(void)
}
-static int write_resolvconf(void) {
+static int write_resolvconf(void)
+{
char * filename = "/etc/resolv.conf";
FILE * f;
@@ -268,7 +269,8 @@ static int write_resolvconf(void) {
}
-static int save_netinfo(struct interface_info * intf) {
+static int save_netinfo(struct interface_info * intf)
+{
char * file_network = "/tmp/network";
char file_intf[500];
FILE * f;
@@ -348,7 +350,8 @@ char * guess_netmask(char * ip_addr)
}
-char * guess_domain_from_hostname(char *hostname) {
+char * guess_domain_from_hostname(char *hostname)
+{
char *domain = strchr(strdup(hostname), '.');
if (!domain || domain[1] == '\0') {
log_message("unable to guess domain from hostname: %s", hostname);