]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Fix a logic bug in makefs lazy inode initialization.
authormarkj <markj@FreeBSD.org>
Sat, 16 Dec 2017 20:19:00 +0000 (20:19 +0000)
committermarkj <markj@FreeBSD.org>
Sat, 16 Dec 2017 20:19:00 +0000 (20:19 +0000)
commitc9ed82aeecfdcd997354c6c68b1089512e4054ec
treeb69be47089f6710800e62822e759ae67f82de03a
parentf0a0836227d10b1a714d129536ff0475a0d6c10b
Fix a logic bug in makefs lazy inode initialization.

We may need to initialize multiple inode blocks before writing a given
inode. makefs(8) was only initializing a single block at a time, so
certain inode allocation patterns could lead to a situation where it
wrote an inode to an uninitialized block. That inode might be clobbered
by a later initialization, resulting in a filesystem image containing
directory entries that point to a seemingly unused inode.

Reviewed by: imp
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D13505
usr.sbin/makefs/ffs.c