Use space after a silencing (void)
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sat, 14 Mar 2015 02:20:01 +0000 (21:20 -0500)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sat, 14 Mar 2015 03:42:17 +0000 (23:42 -0400)
We were using a space more often than not, and this way is
codified in CODING_STYLE.

src/console/consoled-terminal.c
src/core/namespace.c
src/libsystemd-network/lldp-internal.c
src/libsystemd-network/sd-lldp.c
src/libsystemd/sd-bus/bus-socket.c
src/network/networkd-network.c
src/resolve/resolved-dns-scope.c
src/shared/barrier.h
src/shared/ptyfwd.c
src/timedate/timedated.c
src/udev/net/link-config.c

index 3657dca..03447d1 100644 (file)
@@ -98,7 +98,7 @@ Terminal *terminal_free(Terminal *t) {
         assert(t->workspace);
 
         if (t->pty) {
-                (void)pty_signal(t->pty, SIGHUP);
+                (void) pty_signal(t->pty, SIGHUP);
                 pty_close(t->pty);
                 pty_unref(t->pty);
         }
index 6a6d119..3832503 100644 (file)
@@ -150,14 +150,14 @@ static int mount_dev(BindMount *m) {
                 return -errno;
 
         dev = strjoina(temporary_mount, "/dev");
-        (void)mkdir(dev, 0755);
+        (void) mkdir(dev, 0755);
         if (mount("tmpfs", dev, "tmpfs", MS_NOSUID|MS_STRICTATIME, "mode=755") < 0) {
                 r = -errno;
                 goto fail;
         }
 
         devpts = strjoina(temporary_mount, "/dev/pts");
-        (void)mkdir(devpts, 0755);
+        (void) mkdir(devpts, 0755);
         if (mount("/dev/pts", devpts, NULL, MS_BIND, NULL) < 0) {
                 r = -errno;
                 goto fail;
@@ -167,7 +167,7 @@ static int mount_dev(BindMount *m) {
         symlink("pts/ptmx", devptmx);
 
         devshm = strjoina(temporary_mount, "/dev/shm");
-        (void)mkdir(devshm, 01777);
+        (void) mkdir(devshm, 01777);
         r = mount("/dev/shm", devshm, NULL, MS_BIND, NULL);
         if (r < 0) {
                 r = -errno;
@@ -175,11 +175,11 @@ static int mount_dev(BindMount *m) {
         }
 
         devmqueue = strjoina(temporary_mount, "/dev/mqueue");
-        (void)mkdir(devmqueue, 0755);
+        (void) mkdir(devmqueue, 0755);
         mount("/dev/mqueue", devmqueue, NULL, MS_BIND, NULL);
 
         devhugepages = strjoina(temporary_mount, "/dev/hugepages");
-        (void)mkdir(devhugepages, 0755);
+        (void) mkdir(devhugepages, 0755);
         mount("/dev/hugepages", devhugepages, NULL, MS_BIND, NULL);
 
         devlog = strjoina(temporary_mount, "/dev/log");
@@ -273,7 +273,7 @@ static int mount_kdbus(BindMount *m) {
                 return log_error_errno(errno, "Failed create temp dir: %m");
 
         root = strjoina(temporary_mount, "/kdbus");
-        (void)mkdir(root, 0755);
+        (void) mkdir(root, 0755);
         if (mount("tmpfs", root, "tmpfs", MS_NOSUID|MS_STRICTATIME, "mode=777") < 0) {
                 r = -errno;
                 goto fail;
index dee4ea4..0f35446 100644 (file)
@@ -61,7 +61,7 @@ int lldp_read_chassis_id(tlv_packet *tlv,
         *type = subtype;
 
  out1:
-        (void)lldp_tlv_packet_exit_container(tlv);
+        (void) lldp_tlv_packet_exit_container(tlv);
 
  out2:
         return r;
@@ -113,7 +113,7 @@ int lldp_read_port_id(tlv_packet *tlv,
         *type = subtype;
 
  out1:
-        (void)lldp_tlv_packet_exit_container(tlv);
+        (void) lldp_tlv_packet_exit_container(tlv);
 
  out2:
         return r;
@@ -130,7 +130,7 @@ int lldp_read_ttl(tlv_packet *tlv, uint16_t *ttl) {
 
         r = tlv_packet_read_u16(tlv, ttl);
 
-        (void)lldp_tlv_packet_exit_container(tlv);
+        (void) lldp_tlv_packet_exit_container(tlv);
 
  out:
         return r;
@@ -155,7 +155,7 @@ int lldp_read_system_name(tlv_packet *tlv,
         *data = (char *) s;
 
  out:
-        (void)lldp_tlv_packet_exit_container(tlv);
+        (void) lldp_tlv_packet_exit_container(tlv);
 
         return r;
 }
@@ -179,7 +179,7 @@ int lldp_read_system_description(tlv_packet *tlv,
         *data = (char *) s;
 
  out:
-        (void)lldp_tlv_packet_exit_container(tlv);
+        (void) lldp_tlv_packet_exit_container(tlv);
 
         return r;
 }
@@ -203,7 +203,7 @@ int lldp_read_port_description(tlv_packet *tlv,
         *data = (char *) s;
 
  out:
-        (void)lldp_tlv_packet_exit_container(tlv);
+        (void) lldp_tlv_packet_exit_container(tlv);
 
         return r;
 }
@@ -224,7 +224,7 @@ int lldp_read_system_capability(tlv_packet *tlv, uint16_t *data) {
         return 0;
  out:
 
-        (void)lldp_tlv_packet_exit_container(tlv);
+        (void) lldp_tlv_packet_exit_container(tlv);
 
         return r;
 }
index 0821730..fddda97 100644 (file)
@@ -519,7 +519,7 @@ int sd_lldp_save(sd_lldp *lldp, const char *lldp_file) {
                         free(s);
                         s = k;
 
-                        (void)lldp_read_system_capability(p->packet, &data);
+                        (void) lldp_read_system_capability(p->packet, &data);
 
                         sprintf(buf, "'_CAP=%x'", data);
 
index c15929c..873aede 100644 (file)
@@ -606,10 +606,10 @@ void bus_socket_setup(sd_bus *b) {
         /* Enable SO_PASSCRED + SO_PASSEC. We try this on any
          * socket, just in case. */
         enable = !b->bus_client;
-        (void)setsockopt(b->input_fd, SOL_SOCKET, SO_PASSCRED, &enable, sizeof(enable));
+        (void) setsockopt(b->input_fd, SOL_SOCKET, SO_PASSCRED, &enable, sizeof(enable));
 
         enable = !b->bus_client && (b->attach_flags & KDBUS_ATTACH_SECLABEL);
-        (void)setsockopt(b->input_fd, SOL_SOCKET, SO_PASSSEC, &enable, sizeof(enable));
+        (void) setsockopt(b->input_fd, SOL_SOCKET, SO_PASSSEC, &enable, sizeof(enable));
 
         /* Increase the buffers to 8 MB */
         fd_inc_rcvbuf(b->input_fd, SNDBUF_SIZE);
index f7f6eaf..141c36f 100644 (file)
@@ -294,7 +294,7 @@ int network_get(Manager *manager, struct udev_device *device,
 
                                 attr = udev_device_get_sysattr_value(device, "name_assign_type");
                                 if (attr)
-                                        (void)safe_atou8(attr, &name_assign_type);
+                                        (void) safe_atou8(attr, &name_assign_type);
 
                                 if (name_assign_type == NET_NAME_ENUM)
                                         log_warning("%-*s: found matching network '%s', based on potentially unpredictable ifname",
index 1039a5a..ba116de 100644 (file)
@@ -387,7 +387,7 @@ int dns_scope_llmnr_membership(DnsScope *s, bool b) {
                  * one. This is necessary on some devices, such as
                  * veth. */
                 if (b)
-                        (void)setsockopt(fd, IPPROTO_IP, IP_DROP_MEMBERSHIP, &mreqn, sizeof(mreqn));
+                        (void) setsockopt(fd, IPPROTO_IP, IP_DROP_MEMBERSHIP, &mreqn, sizeof(mreqn));
 
                 if (setsockopt(fd, IPPROTO_IP, b ? IP_ADD_MEMBERSHIP : IP_DROP_MEMBERSHIP, &mreqn, sizeof(mreqn)) < 0)
                         return -errno;
@@ -403,7 +403,7 @@ int dns_scope_llmnr_membership(DnsScope *s, bool b) {
                         return fd;
 
                 if (b)
-                        (void)setsockopt(fd, IPPROTO_IPV6, IPV6_DROP_MEMBERSHIP, &mreq, sizeof(mreq));
+                        (void) setsockopt(fd, IPPROTO_IPV6, IPV6_DROP_MEMBERSHIP, &mreq, sizeof(mreq));
 
                 if (setsockopt(fd, IPPROTO_IPV6, b ? IPV6_ADD_MEMBERSHIP : IPV6_DROP_MEMBERSHIP, &mreq, sizeof(mreq)) < 0)
                         return -errno;
index 7816fae..b895469 100644 (file)
@@ -86,6 +86,6 @@ static inline bool barrier_is_aborted(Barrier *b) {
 }
 
 static inline bool barrier_place_and_sync(Barrier *b) {
-        (void)barrier_place(b);
+        (void) barrier_place(b);
         return barrier_sync(b);
 }
index 9d4d61c..789f217 100644 (file)
@@ -342,7 +342,7 @@ int pty_forward_new(
         f->master = master;
 
         if (ioctl(STDOUT_FILENO, TIOCGWINSZ, &ws) >= 0)
-                (void)ioctl(master, TIOCSWINSZ, &ws);
+                (void) ioctl(master, TIOCSWINSZ, &ws);
 
         if (!read_only) {
                 if (tcgetattr(STDIN_FILENO, &f->saved_stdin_attr) >= 0) {
index 9095757..ca771d5 100644 (file)
@@ -739,7 +739,7 @@ int main(int argc, char *argv[]) {
         if (r < 0)
                 goto finish;
 
-        (void)sd_bus_negotiate_timestamp(bus, true);
+        (void) sd_bus_negotiate_timestamp(bus, true);
 
         r = context_read_data(&context);
         if (r < 0) {
index 810a881..361de0d 100644 (file)
@@ -255,7 +255,7 @@ int link_config_get(link_config_ctx *ctx, struct udev_device *device,
 
                                 attr_value = udev_device_get_sysattr_value(device, "name_assign_type");
                                 if (attr_value)
-                                        (void)safe_atou8(attr_value, &name_assign_type);
+                                        (void) safe_atou8(attr_value, &name_assign_type);
 
                                 if (name_assign_type == NET_NAME_ENUM) {
                                         log_warning("Config file %s applies to device based on potentially unpredictable interface name '%s'",