From a8762e43fd6e9ac927e81c13add49a3edcbfcb08 Mon Sep 17 00:00:00 2001 From: David Sterba Date: Thu, 23 Apr 2015 16:40:07 +0200 Subject: btrfs-progs: restore: fix path leak in copy_metadata The path lifecycle spans only this function and we have to free it. Resolves-coverity-id: 1295367 Signed-off-by: David Sterba --- cmds-restore.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cmds-restore.c') diff --git a/cmds-restore.c b/cmds-restore.c index 44581df3..808d1f17 100644 --- a/cmds-restore.c +++ b/cmds-restore.c @@ -612,7 +612,7 @@ static int copy_metadata(struct btrfs_root *root, int fd, } } out: - btrfs_release_path(path); + btrfs_free_path(path); return ret; } -- cgit v1.2.1