]> sourceware.org Git - lvm2.git/commitdiff
bcache: fix memleak on error path
authorZdenek Kabelac <zkabelac@redhat.com>
Wed, 29 Jan 2020 16:31:17 +0000 (17:31 +0100)
committerZdenek Kabelac <zkabelac@redhat.com>
Tue, 4 Feb 2020 16:22:06 +0000 (17:22 +0100)
clang: free io on error path.

lib/device/bcache.c

index 04d49f165693b4c7b0d7970a5dfd8e73f982b9fe..a7d8055261ef18ff9c9bf36686de2a27f2bcaf82 100644 (file)
@@ -515,6 +515,7 @@ static bool _sync_issue(struct io_engine *ioe, enum dir d, int fd,
                                          (unsigned long long)limit_nbytes,
                                          (unsigned long long)extra_nbytes,
                                          (unsigned long long)_last_byte_sector_size);
+                               free(io);
                                return false;
                        }
                }
This page took 0.041779 seconds and 5 git commands to generate.