2002-03-13 01:13:05

by Brian Gerst

[permalink] [raw]
Subject: [PATCH] correction to super_block cleanups

diff -ruN linux/fs/ext2/super.c linux2/fs/ext2/super.c
--- linux/fs/ext2/super.c Tue Mar 12 19:59:57 2002
+++ linux2/fs/ext2/super.c Tue Mar 12 20:03:16 2002
@@ -469,6 +469,7 @@
if (!sbi)
return -ENOMEM;
sb->u.generic_sbp = sbi;
+ memset(sbi, 0, sizeof(struct ext2_super_block));

/*
* See what the current blocksize for the device is, and
diff -ruN linux/fs/ncpfs/inode.c linux2/fs/ncpfs/inode.c
--- linux/fs/ncpfs/inode.c Tue Mar 12 19:59:51 2002
+++ linux2/fs/ncpfs/inode.c Tue Mar 12 20:04:09 2002
@@ -319,6 +319,8 @@
if (!server)
return -ENOMEM;
sb->u.generic_sbp = server;
+ memset(server, 0, sizeof(struct ncp_server));
+
error = -EFAULT;
if (raw_data == NULL)
goto out;


Attachments:
sb-zeroing-1 (715.00 B)
sb-zeroing-2 (705.00 B)
Download all attachments