diff options
author | Ingo Molnar <mingo@elte.hu> | 2011-02-14 13:28:29 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2011-02-14 13:28:31 +0100 |
commit | b366801c95bdbeda811ac9668a3943051a18c188 (patch) | |
tree | 79f08da2ad33a3159e67df344a4c411c88da7db6 /fs/btrfs/super.c | |
parent | eff9073790e1286aa12bf1c65814d3e0132b12e1 (diff) | |
parent | 100b33c8bd8a3235fd0b7948338d6cbb3db3c63d (diff) | |
download | linux-b366801c95bdbeda811ac9668a3943051a18c188.tar.gz linux-b366801c95bdbeda811ac9668a3943051a18c188.tar.bz2 linux-b366801c95bdbeda811ac9668a3943051a18c188.zip |
Merge commit 'v2.6.38-rc4' into x86/numa
Merge reason: Merge latest fixes before applying new patch.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'fs/btrfs/super.c')
-rw-r--r-- | fs/btrfs/super.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c index b2130c46fdb5..a004008f7d28 100644 --- a/fs/btrfs/super.c +++ b/fs/btrfs/super.c @@ -383,7 +383,7 @@ static int btrfs_parse_early_options(const char *options, fmode_t flags, struct btrfs_fs_devices **fs_devices) { substring_t args[MAX_OPT_ARGS]; - char *opts, *p; + char *opts, *orig, *p; int error = 0; int intarg; @@ -397,6 +397,7 @@ static int btrfs_parse_early_options(const char *options, fmode_t flags, opts = kstrdup(options, GFP_KERNEL); if (!opts) return -ENOMEM; + orig = opts; while ((p = strsep(&opts, ",")) != NULL) { int token; @@ -432,7 +433,7 @@ static int btrfs_parse_early_options(const char *options, fmode_t flags, } out_free_opts: - kfree(opts); + kfree(orig); out: /* * If no subvolume name is specified we use the default one. Allocate @@ -623,6 +624,8 @@ int btrfs_sync_fs(struct super_block *sb, int wait) btrfs_wait_ordered_extents(root, 0, 0); trans = btrfs_start_transaction(root, 0); + if (IS_ERR(trans)) + return PTR_ERR(trans); ret = btrfs_commit_transaction(trans, root); return ret; } @@ -761,6 +764,8 @@ static struct dentry *btrfs_mount(struct file_system_type *fs_type, int flags, } btrfs_close_devices(fs_devices); + kfree(fs_info); + kfree(tree_root); } else { char b[BDEVNAME_SIZE]; |