[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Tue, 9 Sep 2008 11:19:55 +0400
From: Alexey Dobriyan <adobriyan@...il.com>
To: Theodore Tso <tytso@....EDU>
Cc: Ralf Hildebrandt <Ralf.Hildebrandt@...rite.de>,
Andreas Dilger <adilger@....com>, akpm@...l.org,
linux-ext4@...r.kernel.org
Subject: Re: [PATCH] ext4: fix #11321: create /proc/ext4/*/stats et al more
carefully
On Mon, Sep 08, 2008 at 10:39:51AM -0400, Theodore Tso wrote:
> --- a/fs/ext4/mballoc.c
> +++ b/fs/ext4/mballoc.c
> @@ -2785,14 +2785,19 @@ static int ext4_mb_init_per_dev_proc(struct super_block *sb)
> mode_t mode = S_IFREG | S_IRUGO | S_IWUSR;
> struct ext4_sb_info *sbi = EXT4_SB(sb);
> struct proc_dir_entry *proc;
> - char devname[64];
> + char devname[64], *p;
>
> if (proc_root_ext4 == NULL) {
> sbi->s_mb_proc = NULL;
> return -EINVAL;
> }
> bdevname(sb->s_bdev, devname);
> + while (p = strchr(p, '/'))
> + *p = '!';
This can't work because "p" is uninitialized. And gcc whines about one
more pair of ().
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists