Btrfs-progs: close file descriptor in cmds-send.c
authorStefan Behrens <sbehrens@giantdisaster.de>
Tue, 9 Apr 2013 17:08:31 +0000 (19:08 +0200)
committerDavid Sterba <dsterba@suse.cz>
Tue, 23 Apr 2013 16:56:22 +0000 (18:56 +0200)
valgrind found this very obvious issue.

Signed-off-by: Stefan Behrens <sbehrens@giantdisaster.de>
cmds-send.c

index 5a7183d0733783b5a996af3fe894eb9e61449cf2..3ba5af673e11bf3ee1e06635303759e5c54bd5fd 100644 (file)
@@ -82,6 +82,7 @@ int find_mount_root(const char *path, char **mount_root)
                        }
                }
        }
+       fclose(mnttab);
 
        *mount_root = realpath(longest_match, NULL);
        free(longest_match);