Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 2 Apr 2021 21:49:41 GMT
From:      Kirk McKusick <mckusick@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: fab7c18ce322 - stable/13 - Fix fsck_ffs Pass 1b error exit "bad inode number 2 to nextinode".
Message-ID:  <202104022149.132Lnf4S017735@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by mckusick:

URL: https://cgit.FreeBSD.org/src/commit/?id=fab7c18ce3229d53b732fdfdbb6e9a1a1c72739a

commit fab7c18ce3229d53b732fdfdbb6e9a1a1c72739a
Author:     Kirk McKusick <mckusick@FreeBSD.org>
AuthorDate: 2021-03-24 23:50:24 +0000
Commit:     Kirk McKusick <mckusick@FreeBSD.org>
CommitDate: 2021-04-02 21:52:49 +0000

    Fix fsck_ffs Pass 1b error exit "bad inode number 2 to nextinode".
    
    (cherry picked from commit bc444e2ec6e6cc9d96d35ab7ce3c02c0da952fad)
---
 sbin/fsck_ffs/pass1b.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/sbin/fsck_ffs/pass1b.c b/sbin/fsck_ffs/pass1b.c
index 8c09ef36acad..b44e0107c982 100644
--- a/sbin/fsck_ffs/pass1b.c
+++ b/sbin/fsck_ffs/pass1b.c
@@ -78,8 +78,10 @@ pass1b(void)
 			continue;
 		setinodebuf(c, inosused);
 		for (i = 0; i < inosused; i++, inumber++) {
-			if (inumber < UFS_ROOTINO)
+			if (inumber < UFS_ROOTINO) {
+				(void)getnextinode(inumber, 0);
 				continue;
+			}
 			dp = getnextinode(inumber, 0);
 			idesc.id_number = inumber;
 			idesc.id_type = inoinfo(inumber)->ino_idtype;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202104022149.132Lnf4S017735>