From owner-svn-src-all@FreeBSD.ORG Wed Feb 10 20:35:21 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 288FA106566C; Wed, 10 Feb 2010 20:35:21 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 165C88FC13; Wed, 10 Feb 2010 20:35:21 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o1AKZKTb001497; Wed, 10 Feb 2010 20:35:20 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o1AKZK0G001495; Wed, 10 Feb 2010 20:35:20 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201002102035.o1AKZK0G001495@svn.freebsd.org> From: Kirk McKusick Date: Wed, 10 Feb 2010 20:35:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r203765 - stable/8/sbin/fsck_ffs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Feb 2010 20:35:21 -0000 Author: mckusick Date: Wed Feb 10 20:35:20 2010 New Revision: 203765 URL: http://svn.freebsd.org/changeset/base/203765 Log: MFC of r201700 | mckusick | 2010-01-06 This corrects a bug that manifested itself as identifying the last cylinder group of a UFS1 filesystem as bad. The error was in the check and not in the cylinder group itself. So even though fsck fixed the cylinder group correctly, it was still endlessly reported as bad. This bug first appeared in 8.0 so does not apply to earlier releases. PR: 141992 Reported by: Dan Strick Modified: stable/8/sbin/fsck_ffs/fsutil.c Directory Properties: stable/8/sbin/fsck_ffs/ (props changed) Modified: stable/8/sbin/fsck_ffs/fsutil.c ============================================================================== --- stable/8/sbin/fsck_ffs/fsutil.c Wed Feb 10 20:17:46 2010 (r203764) +++ stable/8/sbin/fsck_ffs/fsutil.c Wed Feb 10 20:35:20 2010 (r203765) @@ -436,7 +436,7 @@ check_cgmagic(int cg, struct cg *cgp) ((sblock.fs_magic == FS_UFS1_MAGIC && cgp->cg_old_niblk == sblock.fs_ipg && cgp->cg_ndblk <= sblock.fs_fpg && - cgp->cg_old_ncyl == sblock.fs_old_cpg) || + cgp->cg_old_ncyl <= sblock.fs_old_cpg) || (sblock.fs_magic == FS_UFS2_MAGIC && cgp->cg_niblk == sblock.fs_ipg && cgp->cg_ndblk <= sblock.fs_fpg &&