diff options
author | Zhao Lei <zhaolei@cn.fujitsu.com> | 2015-10-26 18:28:20 +0800 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2015-11-02 09:35:08 +0100 |
commit | e72cb5de1211cedc0af2fd9ea4d7535d35c34f76 (patch) | |
tree | 2ff8eb1321dda81479addd3c648976484bb05016 /btrfs-select-super.c | |
parent | da34dbd14936a4c6183be14b7db09f0d6e49cf09 (diff) |
btrfs-progs: Add all missing btrfs_close_all_devices to standalone tools
This patch add all missing btrfs_close_all_devices() to standalone
tools in btrfs progs, to avoid memory leak.
Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'btrfs-select-super.c')
-rw-r--r-- | btrfs-select-super.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/btrfs-select-super.c b/btrfs-select-super.c index b790f3e2..bd44978a 100644 --- a/btrfs-select-super.c +++ b/btrfs-select-super.c @@ -23,6 +23,7 @@ #include <sys/stat.h> #include "kerncompat.h" #include "ctree.h" +#include "volumes.h" #include "disk-io.h" #include "print-tree.h" #include "transaction.h" @@ -101,5 +102,6 @@ int main(int ac, char **av) */ printf("using SB copy %llu, bytenr %llu\n", (unsigned long long)num, (unsigned long long)bytenr); + btrfs_close_all_devices(); return ret; } |