]> sourceware.org Git - lvm2.git/commitdiff
gcc: ensure reset of fd on error path
authorZdenek Kabelac <zkabelac@redhat.com>
Thu, 13 Jun 2024 21:05:19 +0000 (23:05 +0200)
committerZdenek Kabelac <zkabelac@redhat.com>
Wed, 19 Jun 2024 12:28:02 +0000 (14:28 +0200)
daemons/dmeventd/libdevmapper-event.c

index 08df7270f51d230952219208d756142b032afb84..53ddfdfa9739acb227115c0040210bda854d4e3c 100644 (file)
@@ -446,6 +446,7 @@ static int _check_for_usable_fifos(char *dmeventd_path, struct dm_event_fifos *f
                        log_error("%s is no longer a secure root-owned fifo with mode 0600.", fifos->client_path);
                        if (close(fifos->client))
                                log_sys_debug("close", fifos->client_path);
+                       fifos->client = -1;
                        return 0;
                }
 
This page took 0.039036 seconds and 5 git commands to generate.