From 9038c9542258ae35037731e914fee4913a1672eb Mon Sep 17 00:00:00 2001 From: Otto Moerbeek Date: Tue, 22 Jan 2008 09:01:45 +0000 Subject: pick the right csaddr when dumping cgs. Makes FFS2 dumps work much better ok thib@ millert@ --- sbin/dumpfs/dumpfs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sbin/dumpfs') diff --git a/sbin/dumpfs/dumpfs.c b/sbin/dumpfs/dumpfs.c index fc434d851bd..db1ed07f7c2 100644 --- a/sbin/dumpfs/dumpfs.c +++ b/sbin/dumpfs/dumpfs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dumpfs.c,v 1.23 2007/05/21 16:00:27 millert Exp $ */ +/* $OpenBSD: dumpfs.c,v 1.24 2008/01/22 09:01:44 otto Exp $ */ /* * Copyright (c) 2002 Networks Associates Technology, Inc. @@ -48,7 +48,7 @@ static const char copyright[] = #if 0 static const char sccsid[] = "@(#)dumpfs.c 8.5 (Berkeley) 4/29/95"; #else -static const char rcsid[] = "$OpenBSD: dumpfs.c,v 1.23 2007/05/21 16:00:27 millert Exp $"; +static const char rcsid[] = "$OpenBSD: dumpfs.c,v 1.24 2008/01/22 09:01:44 otto Exp $"; #endif #endif /* not lint */ @@ -299,7 +299,7 @@ dumpfs(int fd, const char *name) for (i = 0, j = 0; i < afs.fs_cssize; i += afs.fs_bsize, j++) { size = afs.fs_cssize - i < afs.fs_bsize ? afs.fs_cssize - i : afs.fs_bsize; - off = (off_t)(fsbtodb(&afs, (afs.fs_ffs1_csaddr + j * + off = (off_t)(fsbtodb(&afs, (afs.fs_csaddr + j * afs.fs_frag))) * dev_bsize; if (pread(fd, (char *)afs.fs_csp + i, size, off) != size) goto err; -- cgit v1.2.3