treewide: fix white space errors
authorHans Dedecker <dedeckeh@gmail.com>
Tue, 31 Jan 2017 08:30:27 +0000 (09:30 +0100)
committerHans Dedecker <dedeckeh@gmail.com>
Tue, 31 Jan 2017 08:37:27 +0000 (09:37 +0100)
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
interface.c
iprule.c
system-linux.c
system.h
ubus.c

index a014111aaadb4478ae9e2cdd978d2bc21d767028..522e7fe0c40c888351857e7e6874ea7f8f2d8739 100644 (file)
@@ -94,11 +94,11 @@ interface_error_flush(struct interface *iface)
 static void
 interface_clear_errors(struct interface *iface)
 {
-        /* don't flush the errors in case the configured protocol handler matches the
+       /* don't flush the errors in case the configured protocol handler matches the
            running protocol handler and is having the last error capability */
        if (!(iface->proto &&
-              (iface->proto->handler->flags & PROTO_FLAG_LASTERROR) &&
-              (iface->proto->handler->name == iface->proto_handler->name)))
+             (iface->proto->handler->flags & PROTO_FLAG_LASTERROR) &&
+             (iface->proto->handler->name == iface->proto_handler->name)))
                interface_error_flush(iface);
 }
 
@@ -110,12 +110,12 @@ void interface_add_error(struct interface *iface, const char *subsystem,
        int *datalen = NULL;
        char *dest, *d_subsys, *d_code;
 
-        /* if the configured protocol handler has the last error support capability,
+       /* if the configured protocol handler has the last error support capability,
            errors should only be added if the running protocol handler matches the
            configured one */
        if (iface->proto &&
-            (iface->proto->handler->flags & PROTO_FLAG_LASTERROR) &&
-            (iface->proto->handler->name != iface->proto_handler->name))
+           (iface->proto->handler->flags & PROTO_FLAG_LASTERROR) &&
+           (iface->proto->handler->name != iface->proto_handler->name))
                return;
 
        if (n_data) {
index 4e3dd155cc9b4a92a021d6cfcad3a6c11cb24fd9..81bb77a60c0743b7c76eb84c60b9941145c334bc 100644 (file)
--- a/iprule.c
+++ b/iprule.c
@@ -233,7 +233,7 @@ rule_cmp(const void *k1, const void *k2, void *ptr)
 
 static void
 iprule_update_rule(struct vlist_tree *tree,
-                   struct vlist_node *node_new, struct vlist_node *node_old)
+                       struct vlist_node *node_new, struct vlist_node *node_old)
 {
        struct iprule *rule_old, *rule_new;
 
index fcd1b2e5594f034dbeccfe06f55d2848938d531e..8a1173cf539dfc05ad6f29e54b4660cd41972a2e 100644 (file)
@@ -139,7 +139,7 @@ create_socket(int protocol, int groups)
 
 static bool
 create_raw_event_socket(struct event_socket *ev, int protocol, int groups,
-                        uloop_fd_handler cb, int flags)
+                       uloop_fd_handler cb, int flags)
 {
        ev->sock = create_socket(protocol, groups);
        if (!ev->sock)
@@ -243,7 +243,7 @@ int system_init(void)
                return -1;
 
        if (!create_raw_event_socket(&hotplug_event, NETLINK_KOBJECT_UEVENT, 1,
-                                    handle_hotplug_event, 0))
+                                       handle_hotplug_event, 0))
                return -1;
 
        // Receive network link events form kernel
@@ -1176,10 +1176,10 @@ int system_vlandev_add(struct device *vlandev, struct device *dev, struct vlande
        nlmsg_append(msg, &iim, sizeof(iim), 0);
        nla_put_string(msg, IFLA_IFNAME, vlandev->ifname);
        nla_put_u32(msg, IFLA_LINK, dev->ifindex);
-       
+
        if (!(linkinfo = nla_nest_start(msg, IFLA_LINKINFO)))
                goto nla_put_failure;
-       
+
        nla_put_string(msg, IFLA_INFO_KIND, "vlan");
 
        if (!(data = nla_nest_start(msg, IFLA_INFO_DATA)))
@@ -2231,7 +2231,7 @@ static int system_add_gre_tunnel(const char *name, const char *kind,
                        else
                                tos = 1;
                }
-        }
+       }
 
        if ((cur = tb[TUNNEL_ATTR_INFO]) && (blobmsg_type(cur) == BLOBMSG_TYPE_STRING)) {
                uint8_t icsum, ocsum, iseqno, oseqno;
@@ -2464,7 +2464,7 @@ static int system_add_proto_tunnel(const char *name, const uint8_t proto, const
        struct blob_attr *cur;
        bool set_df = true;
        struct ip_tunnel_parm p  = {
-               .link = link,
+               .link = link,
                .iph = {
                        .version = 4,
                        .ihl = 5,
index e810ed9e94bab307cceeeb40f93d1a495838b344..9c40e4c28cd22f0ef54fd206fb9c5d40d96aaaf4 100644 (file)
--- a/system.h
+++ b/system.h
@@ -41,13 +41,13 @@ extern const struct uci_blob_param_list tunnel_attr_list;
 
 enum bridge_opt {
        /* stp and forward delay always set */
-       BRIDGE_OPT_AGEING_TIME             = (1 << 0),
-       BRIDGE_OPT_HELLO_TIME              = (1 << 1),
-       BRIDGE_OPT_MAX_AGE                 = (1 << 2),
-       BRIDGE_OPT_ROBUSTNESS              = (1 << 3),
-       BRIDGE_OPT_QUERY_INTERVAL          = (1 << 4),
-       BRIDGE_OPT_QUERY_RESPONSE_INTERVAL = (1 << 5),
-       BRIDGE_OPT_LAST_MEMBER_INTERVAL    = (1 << 6),
+       BRIDGE_OPT_AGEING_TIME              = (1 << 0),
+       BRIDGE_OPT_HELLO_TIME               = (1 << 1),
+       BRIDGE_OPT_MAX_AGE                  = (1 << 2),
+       BRIDGE_OPT_ROBUSTNESS               = (1 << 3),
+       BRIDGE_OPT_QUERY_INTERVAL           = (1 << 4),
+       BRIDGE_OPT_QUERY_RESPONSE_INTERVAL  = (1 << 5),
+       BRIDGE_OPT_LAST_MEMBER_INTERVAL     = (1 << 6),
 };
 
 struct bridge_config {
diff --git a/ubus.c b/ubus.c
index 0123b17e62a5bad6cc69f0e5f9a999355a0d6dd4..66f714a5f0ca1976e4b47db024e411d20f916bec 100644 (file)
--- a/ubus.c
+++ b/ubus.c
@@ -402,8 +402,7 @@ netifd_add_interface_errors(struct blob_buf *b, struct interface *iface)
 }
 
 static void
-interface_ip_dump_address_list(struct interface_ip_settings *ip, bool v6,
-                               bool enabled)
+interface_ip_dump_address_list(struct interface_ip_settings *ip, bool v6, bool enabled)
 {
        struct device_addr *addr;
        char *buf;
@@ -619,8 +618,7 @@ interface_ip_dump_prefix_assignment_list(struct interface *iface)
 }
 
 static void
-interface_ip_dump_dns_server_list(struct interface_ip_settings *ip,
-                                  bool enabled)
+interface_ip_dump_dns_server_list(struct interface_ip_settings *ip, bool enabled)
 {
        struct dns_server *dns;
        int buflen = 128;
@@ -637,8 +635,7 @@ interface_ip_dump_dns_server_list(struct interface_ip_settings *ip,
 }
 
 static void
-interface_ip_dump_dns_search_list(struct interface_ip_settings *ip,
-                                  bool enabled)
+interface_ip_dump_dns_search_list(struct interface_ip_settings *ip, bool enabled)
 {
        struct dns_search_domain *dns;