From owner-cvs-sys Mon Aug 4 00:33:02 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id AAA19714 for cvs-sys-outgoing; Mon, 4 Aug 1997 00:33:02 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id AAA19691; Mon, 4 Aug 1997 00:32:25 -0700 (PDT) From: Poul-Henning Kamp Received: (from phk@localhost) by freefall.freebsd.org (8.8.6/8.8.5) id AAA15522; Mon, 4 Aug 1997 00:30:46 -0700 (PDT) Date: Mon, 4 Aug 1997 00:30:46 -0700 (PDT) Message-Id: <199708040730.AAA15522@freefall.freebsd.org> To: cvs-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG, cvs-sys@FreeBSD.ORG Subject: cvs commit: src/sys/ufs/ffs ffs_alloc.c Sender: owner-cvs-sys@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk phk 1997/08/04 00:30:45 PDT Modified files: sys/ufs/ffs ffs_alloc.c Log: We got a couple of "map mismatch" panics from the following code. According to the crash dump, bpref is set to 445 and cgp->cg_nclusterblks is 444. Hence in the for loop, the test fails immediately but the following failure check (got == cgp->cg_nclusterblks) doesn't trigger because got > cgp->cg_nclusterblks. This wreaks havoc in the code after that. Fix: Move one source bit to the left :-) Noticed by: Mike Hibler Submitted by: Kirk McKusick Revision Changes Path 1.34 +2 -2 src/sys/ufs/ffs/ffs_alloc.c