]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
various: remove assignments of unread variables
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 22 Sep 2020 15:30:47 +0000 (17:30 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 22 Sep 2020 15:58:11 +0000 (17:58 +0200)
src/activate/activate.c
src/backlight/backlight.c
src/libsystemd-network/sd-radv.c

index bcc345bf4715140af04a5fe562bc0dc287b8fad6..bca845ad83b9fa828ff44cc21028bb8063d071aa 100644 (file)
@@ -199,7 +199,6 @@ static int exec_process(const char *name, char **argv, char **env, int start_fd,
                                 return log_error_errno(errno, "Failed to dup connection: %m");
 
                         safe_close(start_fd);
-                        start_fd = SD_LISTEN_FDS_START;
                 }
 
                 if (asprintf((char **) (envp + n_env++), "LISTEN_FDS=%zu", n_fds) < 0)
index 682c719f61e6727d08558d7f174577e3ce0d0799..9ee2c23683aad0bcc32e6490dfeb419f185a50f3 100644 (file)
@@ -79,7 +79,7 @@ static int find_pci_or_platform_parent(sd_device *device, sd_device **ret) {
 
         } else if (streq(subsystem, "pci") &&
                    sd_device_get_sysattr_value(parent, "class", &value) >= 0) {
-                unsigned long class = 0;
+                unsigned long class;
 
                 r = safe_atolu(value, &class);
                 if (r < 0)
index 6163cf169143467713c6b64213f840f20e872a59..66a25c7dd80c3da04507b5650a1b1629b3627f76 100644 (file)
@@ -689,7 +689,6 @@ _public_ int sd_radv_add_route_prefix(sd_radv *ra, sd_radv_route_prefix *p, int
         LIST_APPEND(prefix, ra->route_prefixes, p);
         ra->n_route_prefixes++;
 
-        cur = p;
         if (!dynamic) {
                 log_radv("Added prefix %s/%u", strempty(pretty), p->opt.prefixlen);
                 return 0;