Blame SOURCES/dnsmasq-2.76-warning-fixes.patch

33b374
From 13dee6f49e1d035b8069947be84ee8da2af0c420 Mon Sep 17 00:00:00 2001
33b374
From: Simon Kelley <simon@thekelleys.org.uk>
33b374
Date: Tue, 28 Feb 2017 16:51:58 +0000
33b374
Subject: [PATCH] Compilation warning fixes.
33b374
33b374
---
33b374
 src/dbus.c   | 9 ++++-----
33b374
 src/option.c | 3 ++-
33b374
 2 files changed, 6 insertions(+), 6 deletions(-)
33b374
33b374
diff --git a/src/dbus.c b/src/dbus.c
33b374
index 7e0d342..2e1a48e 100644
33b374
--- a/src/dbus.c
33b374
+++ b/src/dbus.c
33b374
@@ -549,17 +549,16 @@ static DBusMessage *dbus_add_lease(DBusMessage* message)
33b374
     return dbus_message_new_error_printf(message, DBUS_ERROR_INVALID_ARGS,
33b374
 					 "Invalid IP address '%s'", ipaddr);
33b374
    
33b374
-  hw_len = parse_hex((char*)hwaddr, dhcp_chaddr, DHCP_CHADDR_MAX, NULL,
33b374
-		     &hw_type);
33b374
+  hw_len = parse_hex((char*)hwaddr, dhcp_chaddr, DHCP_CHADDR_MAX, NULL, &hw_type);
33b374
   if (hw_type == 0 && hw_len != 0)
33b374
     hw_type = ARPHRD_ETHER;
33b374
-
33b374
-    lease_set_hwaddr(lease, dhcp_chaddr, clid, hw_len, hw_type,
33b374
+  
33b374
+  lease_set_hwaddr(lease, dhcp_chaddr, clid, hw_len, hw_type,
33b374
                    clid_len, now, 0);
33b374
   lease_set_expires(lease, expires, now);
33b374
   if (hostname_len != 0)
33b374
     lease_set_hostname(lease, hostname, 0, get_domain(lease->addr), NULL);
33b374
-    
33b374
+  
33b374
   lease_update_file(now);
33b374
   lease_update_dns(0);
33b374
 
33b374
diff --git a/src/option.c b/src/option.c
33b374
index 4a5ef5f..e03b1e3 100644
33b374
--- a/src/option.c
33b374
+++ b/src/option.c
33b374
@@ -4089,7 +4089,7 @@ static void read_file(char *file, FILE *f, int hard_opt)
33b374
     {
33b374
       int white, i;
33b374
       volatile int option = (hard_opt == LOPT_REV_SERV) ? 0 : hard_opt;
33b374
-      char *errmess, *p, *arg = NULL, *start;
33b374
+      char *errmess, *p, *arg, *start;
33b374
       size_t len;
33b374
 
33b374
       /* Memory allocation failure longjmps here if mem_recover == 1 */ 
33b374
@@ -4100,6 +4100,7 @@ static void read_file(char *file, FILE *f, int hard_opt)
33b374
 	  mem_recover = 1;
33b374
 	}
33b374
       
33b374
+      arg = NULL;
33b374
       lineno++;
33b374
       errmess = NULL;
33b374
       
33b374
-- 
33b374
2.9.3
33b374