Date: Sun, 24 Jan 2016 02:25:41 +0000 (UTC) From: "Pedro F. Giffuni" <pfg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r294652 - head/sys/fs/ext2fs Message-ID: <201601240225.u0O2PfRG051928@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: pfg Date: Sun Jan 24 02:25:41 2016 New Revision: 294652 URL: https://svnweb.freebsd.org/changeset/base/294652 Log: ext2: Initialize i_flag after allocation. We use i_flag to carry some flags like IN_E4INDEX which newer ext2fs variants uses internally. fsck.ext3 rightfully complains after our implementation tags non-directory inodes with INDEX_FL. Initializing i_flag during allocation removes the noise factor and quiets down fsck. Patch from: Damjan Jovanovic PR: 206530 Modified: head/sys/fs/ext2fs/ext2_alloc.c Modified: head/sys/fs/ext2fs/ext2_alloc.c ============================================================================== --- head/sys/fs/ext2fs/ext2_alloc.c Sun Jan 24 02:10:05 2016 (r294651) +++ head/sys/fs/ext2fs/ext2_alloc.c Sun Jan 24 02:25:41 2016 (r294652) @@ -393,6 +393,7 @@ ext2_valloc(struct vnode *pvp, int mode, * Linux doesn't read the old inode in when it is allocating a * new one. I will set at least i_size and i_blocks to zero. */ + ip->i_flag = 0; ip->i_size = 0; ip->i_blocks = 0; ip->i_mode = 0;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201601240225.u0O2PfRG051928>