]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
reiserfs: Fix quota mount option parsing
authorJan Kara <jack@suse.cz>
Wed, 21 Dec 2011 16:35:34 +0000 (17:35 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 12 Jan 2012 19:40:02 +0000 (11:40 -0800)
commit a06d789b424190e9f59da391681f908486db2554 upstream.

When jqfmt mount option is not specified on remount, we mistakenly clear
s_jquota_fmt value stored in superblock. Fix the problem.

CC: reiserfs-devel@vger.kernel.org
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
fs/reiserfs/super.c

index f0ad05f380223736cd9a8a121c59d6f1c7ecd7e3..d533daf98dd1b48fe17871c93d9075add3f08e93 100644 (file)
@@ -1149,7 +1149,8 @@ static void handle_quota_files(struct super_block *s, char **qf_names,
                        kfree(REISERFS_SB(s)->s_qf_names[i]);
                REISERFS_SB(s)->s_qf_names[i] = qf_names[i];
        }
-       REISERFS_SB(s)->s_jquota_fmt = *qfmt;
+       if (*qfmt)
+               REISERFS_SB(s)->s_jquota_fmt = *qfmt;
 }
 #endif